aboutsummaryrefslogtreecommitdiff
path: root/src/kernel
diff options
context:
space:
mode:
authorMartin Zumsande <mzumsande@gmail.com>2023-08-23 14:05:42 -0400
committerMartin Zumsande <mzumsande@gmail.com>2024-04-26 13:31:28 -0400
commitd5a631b9597e5029a5048d9b8ad84ea4536bbac0 (patch)
treedaa0b0d0269dfc6bc2d9ad5ff0f180fd753353bc /src/kernel
parent32c80413fdb063199f3bee719c4651bd63f05fce (diff)
validation: improve performance of CheckBlockIndex
by not saving all indexes in a std::multimap, but only those that are not part of the best header chain. The indexes of the best header chain are stored in a vector, which, in the typical case of a mostly linear chain with a few forks, results in a much smaller multimap, and increases performance noticeably for long chains. This does not change the actual consistency checks that are being performed for each index, just the way the block index tree is stored and traversed. Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
Diffstat (limited to 'src/kernel')
0 files changed, 0 insertions, 0 deletions