forked from bitcoin/bitcoin
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
introduce two commandline options for assumeutxo, specifically for benchmarking. these commands are: - pausebackgroundsync - an option lets the user pause the verification of historical blocks in the background -loadutxosnapshot=<path> - load an assumeutxo snapshot on startup, instead of needing to go through the rpc command. the node will shutdown immediately after the snapshot has been loaded this path is not meant for general use and is instead just for making it more ergonomic to use assumeutxo for benchmarking IBD changes. the benefits of using assumeutxo here are we can start from an arbitrary height and sync to chaintip to collect relevant data quickly. using assumeutxo means we can make whatever changes we need to the chainstatedb, since it will be created fresh from the snapshot. note, to use the loadutxosnapshot option, you must first run: ./build/src/bitcoind -stopatheight=1 this makes the node do a header sync and then shut down. this is because assumeutxo will not load a snapshot unless the base block is in the header chain. we could remove this requirement, but this patch is meant to be as minimal as possible, and this also allows us to perform heaeder sync as a preparation commit for a benchmark, which helps keep IBD benchmarks more focused on strictly measuring IBD. next, run: ./build/src/bitcoind -loadutxosnapshot=<path> the node will shutdown after the snapshot is loaded. finally, run: ./build/src/bitcoind -pausebackgroundsync=1 for the actual benchmarking step. this ensures only the sync to chaintip is benchmarked and the load snapshot step is not included in the measurement. Co-authored-by: Sjors Provoost <[email protected]>
- Loading branch information
Showing
6 changed files
with
71 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters