code: func (s *Sync) AddSubTrie(root common.Hash, depth int, parent common.Hash, callback LeafCallback) {
  	// Short circuit if the trie is empty or already known
  	if root == emptyRoot {
  		return
  	}
  	if _, ok := s.membatch.batch[root]; ok {
  		return
  	}
  	key := root.Bytes()
  	blob, _ := s.database.Get(key)
  	if local, err := decodeNode(key, blob); local != nil && err == nil {
  		return
  	}
  	// Assemble the new sub-trie sync request
  	req := &request{
  		hash:     root,
  		depth:    depth,
  		callback: callback,
  	}
  	// If this sub-trie has a designated parent, link them together
  	if parent != (common.Hash{}) {
  		ancestor := s.requests[parent]
  		if ancestor == nil {
  			panic(fmt.Sprintf("sub-trie ancestor not found: %x", parent))
  		}
  		ancestor.deps++
  		req.parents = append(req.parents, ancestor)
  	}
  	s.schedule(req)
  }
docs: // AddSubTrie registers a new trie to the sync code, rooted at the designated parent.