Skip to content

Conversation

@piotrm50
Copy link
Contributor

Description of change

This is a PR to test a potential fix for an issue with the header synchronizer. It limits parallelism of fetching blocks in the HeaderSynchronizer and implements an additional filter to avoid processing redundantly fetched blocks which should reduce CPU usage.

Links to any relevant issues

Resolves #9357

How the change has been tested

  • Basic tests (linting, compilation, formatting, unit/integration tests)
  • Patch-specific tests (correctness, functionality coverage)
  • I have added tests that prove my fix is effective or that my feature works
  • I have checked that new and existing unit tests pass locally with my changes

@piotrm50 piotrm50 self-assigned this Nov 21, 2025
@piotrm50 piotrm50 requested a review from a team as a code owner November 21, 2025 13:02
@piotrm50 piotrm50 added the consensus Issues related to the Core Consensus team label Nov 21, 2025
@vercel
Copy link

vercel bot commented Nov 21, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

6 Skipped Deployments
Project Deployment Preview Comments Updated (UTC)
apps-backend Ignored Ignored Nov 21, 2025 1:03pm
apps-ui-kit Ignored Ignored Nov 21, 2025 1:03pm
iota-evm-bridge Ignored Ignored Nov 21, 2025 1:03pm
iota-multisig-toolkit Ignored Ignored Nov 21, 2025 1:03pm
rebased-explorer Ignored Ignored Nov 21, 2025 1:03pm
wallet-dashboard Ignored Ignored Nov 21, 2025 1:03pm

@piotrm50 piotrm50 changed the title feat(consensus): Limit synchronizer parallelism and add cache for verified blocks feat(starfish): Limit synchronizer parallelism and add cache for verified blocks Nov 24, 2025
&& authorities.get(&peer).is_none()
{

// Check if this peer is already fetching this block
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// Check if this peer is already fetching this block
// Check if this peer is already fetching this header

continue;
}

// Count total authorities currently fetching this block
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// Count total authorities currently fetching this block
// Count total authorities currently fetching this header

Copy link
Member

@polinikita polinikita left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For starfish, this seems to be less important improvement as the most heavy operation is the signature verification which takes 50-100microseconds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

consensus Issues related to the Core Consensus team core-protocol

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Debug and fix high CPU usage preventing the node from catching up when running Synchronizer

4 participants