AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Informational 18 Bitcoin

Rework CTxMemPool::GetChildren() to not use epochs

Public commit record

What the developer wrote

Authored by Suhas Daftuar

83/100 · Strong
Rework CTxMemPool::GetChildren() to not use epochs

This is likely slightly slower, but this was the last place we were using
epochs instead of sets to deduplicate, and this is only used by the RPC code
and in tests, and should not be CPU-performance critical. Eliminating this
allows us to save 8 bytes in CTxMemPoolEntry.

Co-Authored-By: Pieter Wuille <bitcoin-dev@wuille.net>
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
The short version

What changed, and why it matters

This commit is a small internal cleanup in Bitcoin Core's memory pool (mempool) code. It replaces a fast but complex deduplication trick ('epochs') with a simpler, slightly slower approach using sorting. The change saves 8 bytes per mempool entry and removes unused code. There is no indication this fixes a security bug; it appears to be ordinary maintenance/refactoring.

Recommended action

No security action required. Treat as normal code-review/maintenance commit.

Security signals we found

01

No security-relevant signals in commit message or diff

02

Refactoring/cleanup only: removal of Epoch deduplication in favor of sort+unique

03

No input validation, cryptography, network parsing, or consensus code changed

04

No bug pattern (use-after-free, overflow, race, etc.) is corrected by the diff

Risk score

Why this scored 18/100

Our methodology →
Potential impact 2/30
Exploitability 1/25
Stealth signal 1/15
Affected reach 2/15
Confidence 8/10
Evidence quality 4/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.