Pass size to ParseHex to assist preallocation

Shepherd an existing PR to merge which optimizes string to hex conversion.
Not Available
$1,200.00
Check Out Task
Task Bounty Details

18061

Bitcoin Issue

Hours

Estimated Effort

Not Available

Current Status

$1,200.00

Paid in USD or equivalent BTC upon acceptance

Bitcoin Issue

This bounty requires resurrecting an existing PR that has fallen out of date. The PR optimizes use of the `ParseHex()` utility, which converts a string to a vector of bytes.

Hex string decoding is used a number of places in Bitcoin Core, for example in transaction deserialization.

The changes as-written improve the performance of this decoding by a factor of two, and adds benchmarks demonstrating the performance improvement using base64 decoding.

In order to claim this bounty, you should open a replacement PR with the same or similar code changes after rebasing. You should mention the original PR in the description of the replacement PR.

Prerequisite Skills

C++

Code Guidelines

Repository Code Guidelines Page

Definition of Done

Get a PR merged which implements the optimization in the existing PR

Check Out Task