go-ethereum/triedb/pathdb
CPerezz b4caa05448
core/state,triedb/pathdb: add pre-benchmark validation tests
Comprehensive validation suite designed to confirm the flat state is
working before running benchmarks.

TestBintrieFlatStateConsistencyOracle (core/state):
  The "if this passes, we're good to benchmark" test. Builds realistic
  state over 15 blocks (48 accounts, 14 storage slots), explicitly
  flushes to disk at block 5, and verifies structural invariants of
  every flat-state read at every block commit. Covers:
  - Diff-layer chaining across 15 blocks
  - Disk-layer reads after explicit flush (A1 smoking gun)
  - Account creation, balance/nonce modification, code deployment
  - Storage write, update, and tombstone (zero-value clear)
  - Post-flush state evolution with fresh diff layers on top of disk

Stem blob edge cases (triedb/pathdb):
  TestStemBlobOffset127_128Boundary — validates the bitmap byte
  boundary between the last header storage offset (127) and the first
  code chunk offset (128). A bitmapRank off-by-one here would cause
  extractStemOffset to return the adjacent offset's value.

  TestStemBlobFull256DeleteMiddle — fully populates all 256 offsets,
  deletes one from the middle (offset 128), verifies all 255 remaining
  values survive at the correct positions.

  TestFlushIdempotency — verifies that flushing the same data twice
  produces a byte-identical on-disk blob. The RMW in applyWrites must
  be idempotent to handle overlapping diff-layer merges.
2026-04-15 15:00:41 +02:00
..
buffer.go triedb/pathdb: replace crit panic shim with error propagation through Flush 2026-04-15 15:00:41 +02:00
config.go triedb/pathdb: enhance history index initer (#33640) 2026-03-17 15:29:30 +01:00
context.go triedb/pathdb: thread flatStateCodec through internals 2026-04-15 15:00:39 +02:00
database.go core/state,triedb/pathdb: enable bintrie flat state reads end-to-end 2026-04-15 15:00:40 +02:00
database_test.go core, eth, ethclient, triedb: report trienode index progress (#34633) 2026-04-04 21:00:07 +08:00
difflayer.go triedb/pathdb: return nodeLoc by value to avoid heap allocation (#33819) 2026-02-11 22:14:43 +08:00
difflayer_test.go cmd, core, eth, triedb/pathdb: track node origins in the path database (#32418) 2025-09-05 10:37:05 +08:00
disklayer.go triedb/pathdb: replace crit panic shim with error propagation through Flush 2026-04-15 15:00:41 +02:00
errors.go core, triedb/pathdb: final integration (snapshot integration pt 5) (#30661) 2025-05-16 18:29:38 +08:00
execute.go cmd, core, eth, triedb/pathdb: track node origins in the path database (#32418) 2025-09-05 10:37:05 +08:00
fileutils_unix.go triedb/pathdb: introduce file-based state journal (#32060) 2025-07-15 11:45:20 +08:00
fileutils_windows.go triedb/pathdb: introduce file-based state journal (#32060) 2025-07-15 11:45:20 +08:00
flat_codec.go triedb/pathdb: replace crit panic shim with error propagation through Flush 2026-04-15 15:00:41 +02:00
flat_codec_bintrie.go core/state,triedb/pathdb: doc accuracy sweep — remove stale temporal markers 2026-04-15 15:00:41 +02:00
flat_codec_bintrie_test.go triedb/pathdb: replace crit panic shim with error propagation through Flush 2026-04-15 15:00:41 +02:00
flush.go triedb/pathdb: replace crit panic shim with error propagation through Flush 2026-04-15 15:00:41 +02:00
generate.go core/state,triedb/pathdb: enable bintrie flat state reads end-to-end 2026-04-15 15:00:40 +02:00
generate_bintrie.go triedb/pathdb: fix mid-stem generator resume via mergeStemBlob RMW 2026-04-15 15:00:41 +02:00
generate_bintrie_test.go core/state,triedb/pathdb: add integration tests for storage tombstone, multi-block evolution, and contract code generation 2026-04-15 15:00:41 +02:00
generate_test.go triedb/pathdb, eth: use double-buffer mechanism in pathdb (#30464) 2025-06-22 20:40:54 +08:00
history.go core/rawdb, triedb/pathdb: enable trienode history alongside existing data (#33934) 2026-03-12 09:21:54 +08:00
history_index.go triedb/pathdb: improve trienode reader for searching (#33681) 2026-01-27 20:05:35 +08:00
history_index_block.go triedb/pathdb: improve trienode reader for searching (#33681) 2026-01-27 20:05:35 +08:00
history_index_block_test.go triedb/pathdb: introduce extension to history index structure (#33399) 2026-01-08 09:57:35 +01:00
history_index_iterator.go core, eth, internal, triedb/pathdb: enable eth_getProofs for history (#32727) 2026-01-22 09:19:27 +08:00
history_index_iterator_test.go core, eth, internal, triedb/pathdb: enable eth_getProofs for history (#32727) 2026-01-22 09:19:27 +08:00
history_index_pruner.go triedb/pathdb: implement history index pruner (#33999) 2026-04-02 00:21:58 +02:00
history_index_pruner_test.go triedb/pathdb: implement history index pruner (#33999) 2026-04-02 00:21:58 +02:00
history_index_test.go triedb/pathdb: introduce extension to history index structure (#33399) 2026-01-08 09:57:35 +01:00
history_indexer.go triedb/pathdb: implement history index pruner (#33999) 2026-04-02 00:21:58 +02:00
history_indexer_state.go triedb/pathdb: enhance history index initer (#33640) 2026-03-17 15:29:30 +01:00
history_indexer_test.go triedb/pathdb: enhance history index initer (#33640) 2026-03-17 15:29:30 +01:00
history_inspect.go triedb/pathdb: allow single-element history ranges (#33329) 2025-12-01 10:19:21 +08:00
history_reader.go triedb/pathdb: improve trienode reader for searching (#33681) 2026-01-27 20:05:35 +08:00
history_reader_test.go triedb/pathdb: implement trienode history indexing scheme (#33551) 2026-01-17 20:28:37 +08:00
history_state.go triedb/pathdb: implement trienode history indexing scheme (#33551) 2026-01-17 20:28:37 +08:00
history_state_test.go core/rawdb, triedb/pathdb: introduce trienode history (#32596) 2025-10-10 14:51:27 +08:00
history_trienode.go triedb/pathdb: preallocate slices in decodeRestartTrailer (#33715) 2026-01-30 21:14:15 +08:00
history_trienode_test.go triedb/pathdb: improve trienode reader for searching (#33681) 2026-01-27 20:05:35 +08:00
history_trienode_utils.go triedb/pathdb: implement trienode history indexing scheme (#33551) 2026-01-17 20:28:37 +08:00
history_trienode_utils_test.go triedb/pathdb: implement trienode history indexing scheme (#33551) 2026-01-17 20:28:37 +08:00
holdable_iterator.go trie/pathdb: state iterator (snapshot integration pt 4) (#30654) 2024-12-16 21:10:08 +08:00
holdable_iterator_test.go trie/pathdb: state iterator (snapshot integration pt 4) (#30654) 2024-12-16 21:10:08 +08:00
iterator.go triedb, triedb/internal, triedb/pathdb: add GenerateTrie + extract shared pipeline into triedb/internal (#34654) 2026-04-07 14:36:53 +08:00
iterator_binary.go triedb/pathdb, eth: use double-buffer mechanism in pathdb (#30464) 2025-06-22 20:40:54 +08:00
iterator_fast.go triedb/pathdb, eth: use double-buffer mechanism in pathdb (#30464) 2025-06-22 20:40:54 +08:00
iterator_test.go triedb/pathdb: thread flatStateCodec through internals 2026-04-15 15:00:39 +02:00
journal.go core/state,triedb/pathdb: doc accuracy sweep — remove stale temporal markers 2026-04-15 15:00:41 +02:00
layertree.go triedb/pathdb: fix lookup sentinel collision with zero disk layer root (#34680) 2026-04-09 13:39:38 +08:00
layertree_test.go triedb/pathdb: fix lookup sentinel collision with zero disk layer root (#34680) 2026-04-09 13:39:38 +08:00
lookup.go triedb/pathdb: fix lookup sentinel collision with zero disk layer root (#34680) 2026-04-09 13:39:38 +08:00
metrics.go triedb/pathdb: implement history index pruner (#33999) 2026-04-02 00:21:58 +02:00
nodes.go core, eth, internal, triedb/pathdb: enable eth_getProofs for history (#32727) 2026-01-22 09:19:27 +08:00
nodes_test.go rlp, trie, triedb/pathdb: compress trienode history (#32913) 2026-01-08 21:58:02 +08:00
reader.go core/state,triedb/pathdb: enable bintrie flat state reads end-to-end 2026-04-15 15:00:40 +02:00
states.go triedb/pathdb: replace crit panic shim with error propagation through Flush 2026-04-15 15:00:41 +02:00
states_test.go all: update license comments and AUTHORS (#31133) 2025-02-05 23:01:17 +01:00
stem_blob.go core/state,triedb/pathdb: add defensive length checks in encodeBinary and encodeStemBlob 2026-04-15 15:00:41 +02:00
stem_blob_edge_test.go core/state,triedb/pathdb: add pre-benchmark validation tests 2026-04-15 15:00:41 +02:00
stem_blob_test.go triedb/pathdb: implement bintrieFlatCodec + stem blob helpers 2026-04-15 15:00:40 +02:00
verifier.go triedb, triedb/internal, triedb/pathdb: add GenerateTrie + extract shared pipeline into triedb/internal (#34654) 2026-04-07 14:36:53 +08:00