This commit is taken from https://github.com/bitcoin-core/univalue-subtree/commit/284f76366b085f6de9ffaa1d7767de71eab2868e (first commit of https://github.com/bitcoin-core/univalue-subtree/pull/27).
univalue: hand written conversion of number to string #25711
pull maflcko wants to merge 1 commits into bitcoin:master from maflcko:2207-faster-univalue-💡 changing 2 files +61 −10-
maflcko commented at 12:55 PM on July 26, 2022: member
-
32bd837332
hand written conversion of number to string
The function appendNumToString is much faster than using a temporary ostringstream. The implementation is locale independent, and does not allocate any additional memory. In my tests, Bitcoin's BlockToJsonVerbose benchmark runs ~11% faster with that patch. Also added a test for the corner cases.
- maflcko added the label Refactoring on Jul 26, 2022
-
maflcko commented at 3:00 PM on July 26, 2022: member
This needs the sanitizer warning fixed somehow, so I am leaving it for others to pick up, if they want.
- maflcko closed this on Jul 26, 2022
- maflcko deleted the branch on Jul 26, 2022
- fanquake added the label Up for grabs on Jul 26, 2022
- bitcoin locked this on Jul 26, 2023
- maflcko removed the label Up for grabs on Jul 24, 2025
Contributors
Labels