-
Notifications
You must be signed in to change notification settings - Fork 221
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add bulletproof rewind profiling (#3618)
Description --- The following changes were made: - Added bulletproof rewind profiling measurements. - Improved wallet recovery resiliency with improved connection logic to the selected base node(s). - Improved recovering of seed words usability. - Improved some struct member names to be less confusing. - Improved recovery UTXO streaming performance by tuning the chunking parameter. **Results** The following tests were run using standard Tor connectivity on a laptop with an Intel(R) Core(TM) i7-7820HQ CPU and basic Samsung NVMe storage device. | Number of outputs | 52654 | 52284 | 52753 | 52762 | 52762 | | ------------------------------- | ------ | ------ | ------ | ----- | ------ | | Chunk size | 10 | 100 | 250 | 125 | 125 | | Stream form base node time (ms) | 197678 | 108757 | 236872 | 96274 | 115798 | | - per output (ms) | 3.754 | 2.080 | 4.490 | 1.825 | 2.195 | | - normalized | 0.836 | 0.463 | 1 | 0.406 | 0.489 | | Total processing time (ms) | 77157 | 72653 | 69005 | 67170 | 68563 | | - per output (ms) | 1.465 | 1.39 | 1.308 | 1.273 | 1.299 | | - normalized | 1 | 0.949 | 0.893 | 0.869 | 0.887 | | Bulletproofs rewind time (ms) | 10877 | 11040 | 10665 | 10854 | 10702 | | - per output (ms) | 0.207 | 0.211 | 0.202 | 0.206 | 0.203 | | - normalized | 0.981 | 1 | 0.957 | 0.976 | 0.962 | **Discussion** - As can be seen, Bulletproof rewind performance was consistently measured at ~0.21ms per output. - Total processing time, which includes all database processing and Bulletproof rewinding, averaged at about 1.35ms per output. - Optimum streaming performance was found to be ~2ms per output. - Output streaming performance was found to be closely related to the chunk size that are requested from the base node. Smaller (10) and larger (250) quantities were the worst performers, while a quantity in the range of 100 to 125 was approximately twice as fast. _For this PR a final chunk size value of 125 was chosen._ Motivation and Context --- - Further code improvements can be based on informed decisions using the profiling information as basis. How Has This Been Tested? --- - Unit testing. - Cucumber testing. - System-level testing doing wallet recoveries.
- Loading branch information
1 parent
b09acd1
commit 5790a9d
Showing
9 changed files
with
477 additions
and
4,533 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
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
Oops, something went wrong.