Skip to content

Attestation Processing Performance Bottleneck - [Phase0] #409

@EchoAlice

Description

@EchoAlice

Description

epoch_processing::get_inclusion_delay_deltas() creates a significant performance bottleneck in state_transition(). At slot 3,200, processing takes ~3.92 days due to inefficient attestation iteration.

Impact

  • Blocks epoch boundary processing
  • Affects validator reward calculations
  • Prevents timely consensus

Current Implementation

// O(validators × pending_attestations)
for validator in unslashed_validators {
    for attestation in pending_attestations {
        // Process attestations
    }
}

Metrics

(at slot 3,200)

  • 20,488 validators
  • 225 pending attestations
  • 4.6M attestation batches
  • 73.5ms per batch

0.0735 x 4,600,000 = ~3.92 days

Proposed Solution

Restructure to single-pass attestation processing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions