Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ReceiveBlockNoPubsubForkchoice should not update block tree cache #4541

Merged
merged 2 commits into from Jan 14, 2020

Conversation

terencechain
Copy link
Member

@terencechain terencechain commented Jan 14, 2020

One of the bottleneck during round robin sync for ReceiveBlockNoPubsubForkchoice is updating filtered tree cache every slot. This is not needed as suggested by the method name, we do not care about fork choice nor compute for head during ReceiveBlockNoPubsubForkchoice

Screen Shot 2020-01-13 at 10 25 32 PM

To fix this, we implemented OnBlockCacheFilteredTree which inherits OnBlock plus updating the filtered block tree cache. And make OnBlockCacheFilteredTree called from ReceiveBlockNoPubsub. Much better looking flame:

Screen Shot 2020-01-13 at 10 52 06 PM

@terencechain terencechain self-assigned this Jan 14, 2020
@terencechain terencechain added the Ready For Review A pull request ready for code review label Jan 14, 2020
@terencechain terencechain merged commit 6ef1a71 into master Jan 14, 2020
@delete-merged-branch delete-merged-branch bot deleted the on-block-no-fork-choice branch January 14, 2020 16:05
cryptomental pushed a commit to cryptomental/prysm that referenced this pull request Feb 24, 2020
cryptomental pushed a commit to cryptomental/prysm that referenced this pull request Feb 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ready For Review A pull request ready for code review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants