Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

Remove loop in ReplayStage #8493

Merged
merged 1 commit into from
Feb 27, 2020
Merged

Conversation

carllin
Copy link
Contributor

@carllin carllin commented Feb 27, 2020

Problem

ReplayStage unnecessarily loops through the compute_stats, select_fork logic

Added here:

3776d3a#diff-5984b6b0429f857c13a2a362669ab37cR329

with the intention that a validator would vote on all ancestors of the heaviest bank. However, with the introduction of fork weights, the validator will always pick the tip of the fork anyways, skipping hte ancestors.

Summary of Changes

Remove the loop

Fixes #

@carllin carllin requested a review from aeyakovenko February 27, 2020 01:58
@carllin carllin changed the title Remove loop Remove loop in ReplayStage Feb 27, 2020
@codecov
Copy link

codecov bot commented Feb 27, 2020

Codecov Report

Merging #8493 into master will decrease coverage by 0.0%.
The diff coverage is n/a.

@@           Coverage Diff            @@
##           master   #8493     +/-   ##
========================================
- Coverage    80.3%   80.3%   -0.1%     
========================================
  Files         256     256             
  Lines       56481   56475      -6     
========================================
- Hits        45361   45354      -7     
- Misses      11120   11121      +1     

@carllin carllin merged commit 5f766cd into solana-labs:master Feb 27, 2020
mergify bot pushed a commit that referenced this pull request Feb 27, 2020
(cherry picked from commit 5f766cd)

# Conflicts:
#	core/src/replay_stage.rs
mergify bot pushed a commit that referenced this pull request Feb 27, 2020
(cherry picked from commit 5f766cd)

# Conflicts:
#	core/src/replay_stage.rs
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant