Optimize scheduler#2067
Merged
Merged
Conversation
Contributor
Author
|
benchmark |
Benchmark Result
|
Contributor
Author
|
benchmark |
Benchmark Result
|
25e539c to
70b6265
Compare
Contributor
Author
|
benchmark |
Benchmark Result
|
70b6265 to
1bf3a58
Compare
quake
requested changes
May 18, 2020
16bf17d to
4790ced
Compare
4790ced to
a48ae6a
Compare
Member
|
@quake plans to give a better distribution models in simulation test to find better parameters after @keroro520 has collected new metrics. Before that we can merge this PR when there's no problems on the algorithm itself. |
quake
previously approved these changes
Jun 12, 2020
doitian
requested changes
Jun 18, 2020
a48ae6a to
f7375ae
Compare
doitian
requested changes
Jun 19, 2020
f7375ae to
7f4e1d9
Compare
doitian
previously approved these changes
Jun 19, 2020
7f4e1d9 to
4b9de89
Compare
quake
approved these changes
Jun 19, 2020
Member
|
Sorry that I misunderstood #2067 (comment) , the original code looks good. |
doitian
approved these changes
Jun 19, 2020
Member
|
bors r=quake,doitian |
Contributor
|
Build succeeded: |
Member
|
The latest test result. The unit is block counts per second, higher is better.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problems with the current scheduler:
This PR implements an adaptive scheduler based on past data, removing most of the redundant calculations. Translating the overall data into 4 intervals:
| fast | normal | penalty | double penalty |
The dividing line is the 1/3 position, 4/5 position, 1/10 position.
There is a 14/30 normal area, 1/10 penalty area, 1/10 double penalty area, 1/3 accelerated reward area.
Replace the 30-second clear-out strategy with a doubling penalty.
10%-20% increase in sync performance from testing, from 220-240 block/s to 250-270 block/s on a dual-core machine
the simulation test: https://github.com/nervosnetwork/sync-scheduler-simulation-test