Skip to content

Commit

Permalink
headerssync: update params for 26.x
Browse files Browse the repository at this point in the history
  • Loading branch information
fanquake committed Oct 5, 2023
1 parent f12f92b commit b2ede22
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions contrib/devtools/headerssync-params.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
# Parameters:

# Aim for still working fine at some point in the future. [datetime]
TIME = datetime(2026, 5, 25)
TIME = datetime(2026, 10, 5)

# Expected block interval. [timedelta]
BLOCK_INTERVAL = timedelta(seconds=600)

# The number of headers corresponding to the minchainwork parameter. [headers]
MINCHAINWORK_HEADERS = 784000
MINCHAINWORK_HEADERS = 804000

# Combined processing bandwidth from all attackers to one victim. [bit/s]
# 6 Gbit/s is approximately the speed at which a single thread of a Ryzen 5950X CPU thread can hash
Expand Down
4 changes: 2 additions & 2 deletions src/headerssync.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
// contrib/devtools/headerssync-params.py.

//! Store one header commitment per HEADER_COMMITMENT_PERIOD blocks.
constexpr size_t HEADER_COMMITMENT_PERIOD{600};
constexpr size_t HEADER_COMMITMENT_PERIOD{606};

//! Only feed headers to validation once this many headers on top have been
//! received and validated against commitments.
constexpr size_t REDOWNLOAD_BUFFER_SIZE{14308}; // 14308/600 = ~23.8 commitments
constexpr size_t REDOWNLOAD_BUFFER_SIZE{14441}; // 14441/606 = ~23.8 commitments

// Our memory analysis assumes 48 bytes for a CompressedHeader (so we should
// re-calculate parameters if we compress further)
Expand Down

0 comments on commit b2ede22

Please sign in to comment.