Integrate @JoelKatz's optimized ToHex (#562) into current HexStr function #1131

pull laanwj wants to merge 1 commits into bitcoin:master from laanwj:2012_04_hexstr changing 2 files +25 −9
  1. laanwj commented at 6:48 PM on April 21, 2012: member

    Pull request #562 was rejected because it introduced a new ToHex function with a different, potentially less safe interface.

    This pull request gives most of the speed-up (~30x on my CPU) of @JoelKatz his patch but rolls it into the current HexStr function. See the following benchmark results (made using https://gist.github.com/2439041).

    Testing HexStrOld (1000000 iterations)
    -> 14120.0 ms
    Testing HexStrNew (1000000 iterations)
    -> 470.0 ms
    Testing ToHex (1000000 iterations)
    -> 100.0 ms
    

    It also adds two tests for HexStr: testing HexStr for the empty string and the function that takes a std::vector.

  2. Integrate @JoelKatz's optimized ToHex (#562) into current HexStr function 88dc2d6c6a
  3. jgarzik commented at 7:46 PM on April 21, 2012: contributor

    ACK

  4. sipa commented at 9:04 PM on April 21, 2012: member

    ACK

  5. gavinandresen commented at 11:21 PM on April 21, 2012: contributor

    ACK

  6. sipa referenced this in commit 7dbe393629 on Apr 21, 2012
  7. sipa merged this on Apr 21, 2012
  8. sipa closed this on Apr 21, 2012

  9. coblee referenced this in commit fa27abf991 on Jul 17, 2012
  10. laanwj deleted the branch on Apr 9, 2014
  11. suprnurd referenced this in commit bc96f288ed on Dec 5, 2017
  12. lateminer referenced this in commit de0940c6a8 on Jan 22, 2019
  13. lateminer referenced this in commit 8ca5db691b on Dec 25, 2019
  14. DrahtBot locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-13 15:16 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me