Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Tokens]Switch CCoinsView and chainstate db from per-txid to per-txout #121

@FornaxA

Description

@FornaxA

See bitcoin/bitcoin@5083079

"This patch makes several related changes:

  • Changes the CCoinsView virtual methods (GetCoins, HaveCoins, ...)
    to be COutPoint/Coin-based rather than txid/CCoins-based.
  • Changes the chainstate db to a new incompatible format that is also COutPoint/Coin based.
  • Implements reconstruction code for hash_serialized_2.
  • Adapts the coins_tests unit tests (thanks to Russell Yanofsky).

A side effect of the new CCoinsView model is that we can no longer use the (unreliable) test for transaction outputs in the UTXO set to determine whether we already have a particular transaction."

Many recent BTC features use the CCoin format instead of the CCoins format.

Part of the functionality has currently already been incorporated in the forms of wrappers that e.g. convert between CCoins and CCoin or between COutpoint and txid.

Completing the transformation will improve performance and provide building blocks for future backports.

Metadata

Metadata

Assignees

Labels

BackportPorting from upstreamFeatureFeature request, user suggestions and enhancements whic are not part of any milestoneTokensThis is everything we are doing to add Tokens to IONmaintenanceMaintenance related

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions