code: func (bi *blockIndex) AddNode(node *blockNode) {
  	bi.Lock()
  	bi.addNode(node)
  	bi.dirty[node] = struct{}{}
  	bi.Unlock()
  }
docs: // AddNode adds the provided node to the block index and marks it as dirty.
  // Duplicate entries are not checked so it is up to caller to avoid adding them.
  //
  // This function is safe for concurrent access.