Page MenuHomePhabricator

Update univalue to 1.1.1

Authored by jasonbcox on May 13 2020, 22:47.



Update univalue to 1.1.1

This improves getblocktemplate performance by ~28% on my machine.
Exerpt from which is
the primary change associated with the perf improvement:

When the hand-written destructor is removed, the compiler will
automatically create a proper one, with correct noexcept. This
allows std::vector<UniValue> to be resized without having to copy
all elements first, which makes JSON generation of a bitcoin block
(as in the benchmark "BlockToJsonVerbose") 25% faster on my machine.

Author: @martinus

This update also includes some nice cleanup and a new reserve()
function that may allow us to squeeze out some more performance
in a few places.

Test Plan
ninja check check-functional check-univalue

Diff Detail

rABC Bitcoin ABC
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

jasonbcox created this revision.May 13 2020, 22:47
Herald added a reviewer: Restricted Project. · View Herald TranscriptMay 13 2020, 22:47
jasonbcox requested review of this revision.May 13 2020, 22:47
deadalnix accepted this revision.May 13 2020, 23:00
This revision is now accepted and ready to land.May 13 2020, 23:00
This revision was automatically updated to reflect the committed changes.