p2p: cache block hash in ProcessGetBlockData and CMPCTBLOCK processing #26782

pull andrewtoth wants to merge 1 commits into bitcoin:master from andrewtoth:cache-block-header-hash changing 1 files +13 −9
  1. andrewtoth commented at 6:25 PM on December 31, 2022: contributor

    Inspired by #23819.

    CBlockHeader doesn't store its hash, so it has to serialize and hash it again in every call. This PR caches the hash when processing block GETDATA and CMPCTBLOCK requests.

  2. p2p: cache block hash in ProcessGetBlockData and CMPCTBLOCK processing e5e7330fb9
  3. DrahtBot commented at 6:25 PM on December 31, 2022: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline for information on the review process. A summary of reviews will appear here.

  4. DrahtBot added the label P2P on Dec 31, 2022
  5. andrewtoth closed this on Dec 31, 2022

  6. bitcoin locked this on Dec 31, 2023

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-30 00:13 UTC

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