HomePhabricator

ModifyNewCoins saves database lookups
14470f9aa6baUnpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

ModifyNewCoins saves database lookups

When processing a new transaction, in addition to spending the Coins of its txin's it creates a new Coins for its outputs. The existing ModifyCoins function will first make sure this Coins does not already exist. It can not exist due to BIP 30, but because of that the lookup can't be cached and always has to go to the database. Since we are creating the coins to match the new tx anyway, there is no point in checking if they exist first anyway. However this should not be used for coinbase tx's in order to preserve the historical behavior of overwriting the two existing duplicate tx pairs.

Details

Provenance
Alex Morcos <morcos@chaincode.com>Authored on Nov 3 2015, 02:27
deadalnixPushed on May 14 2017, 22:04
Parents
rABC8fe30fb4d130: Merge pull request #6928
Branches
Unknown
Tags
Unknown

Event Timeline

Alex Morcos <morcos@chaincode.com> committed rABC14470f9aa6ba: ModifyNewCoins saves database lookups (authored by Alex Morcos <morcos@chaincode.com>).Nov 3 2015, 02:27