-
Notifications
You must be signed in to change notification settings - Fork 5
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
Replace level assignment algo #31
Merged
Merged
Conversation
This file contains 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
Level assignment/old/10 time: [4.6777 µs 4.6968 µs 4.7203 µs] change: [+29.037% +29.475% +29.944%] (p = 0.00 < 0.05) Performance has regressed. Found 9 outliers among 100 measurements (9.00%) 1 (1.00%) low mild 7 (7.00%) high mild 1 (1.00%) high severe Level assignment/new/10 time: [3.6707 µs 3.6766 µs 3.6832 µs] change: [-15.488% -15.232% -14.986%] (p = 0.00 < 0.05) Performance has improved. Found 6 outliers among 100 measurements (6.00%) 3 (3.00%) high mild 3 (3.00%) high severe Level assignment/old/20 time: [16.975 µs 17.010 µs 17.048 µs] change: [+139.46% +141.70% +143.47%] (p = 0.00 < 0.05) Performance has regressed. Found 1 outliers among 100 measurements (1.00%) 1 (1.00%) high mild Level assignment/new/20 time: [6.9723 µs 6.9910 µs 7.0104 µs] change: [-60.509% -60.295% -60.080%] (p = 0.00 < 0.05) Performance has improved. Found 4 outliers among 100 measurements (4.00%) 3 (3.00%) high mild 1 (1.00%) high severe Level assignment/old/30 time: [38.714 µs 38.816 µs 38.929 µs] change: [+269.68% +271.00% +272.37%] (p = 0.00 < 0.05) Performance has regressed. Found 6 outliers among 100 measurements (6.00%) 6 (6.00%) high mild Level assignment/new/30 time: [10.633 µs 10.658 µs 10.686 µs] change: [-72.727% -72.645% -72.561%] (p = 0.00 < 0.05) Performance has improved. Found 6 outliers among 100 measurements (6.00%) 1 (1.00%) low mild 2 (2.00%) high mild 3 (3.00%) high severe Level assignment/old/60 time: [152.78 µs 153.18 µs 153.61 µs] change: [+643.88% +647.00% +649.97%] (p = 0.00 < 0.05) Performance has regressed. Found 3 outliers among 100 measurements (3.00%) 3 (3.00%) high mild Level assignment/new/60 time: [20.442 µs 20.586 µs 20.822 µs] change: [-86.798% -86.734% -86.664%] (p = 0.00 < 0.05) Performance has improved. Found 9 outliers among 100 measurements (9.00%) 7 (7.00%) high mild 2 (2.00%) high severe Level assignment/old/120 time: [651.89 µs 653.46 µs 655.03 µs] change: [+1547.9% +1553.7% +1559.5%] (p = 0.00 < 0.05) Performance has regressed. Found 4 outliers among 100 measurements (4.00%) 3 (3.00%) high mild 1 (1.00%) high severe Level assignment/new/120 time: [40.250 µs 40.348 µs 40.448 µs] change: [-93.739% -93.721% -93.703%] (p = 0.00 < 0.05) Performance has improved. Found 1 outliers among 100 measurements (1.00%) 1 (1.00%) high mild
The best of the three is the new rust algo
Cool! Can you share any details about the dependency graph structure that you used for your experiments? |
oowekyala
force-pushed
the
clem.new-graph-search
branch
from
September 19, 2022 08:49
90cb523
to
7b8839d
Compare
cmnrd
reviewed
Sep 20, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
cmnrd
approved these changes
Sep 20, 2022
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.
I suspected the algorithm is exponential for some types of graph, and measured that this is the case. This PR replaces the algo with something that stays linear. I also compared with the algorithm used by the C++ runtime (ported to Rust). The Rust algorithm of this PR scales better on this specific type of graph, but I didn't do any tests on more normal graphs. This is anyway not a performance critical part of the runtime, but this TODO comment had been irking me for a while....
Here's a graph produced by the benhmarking framework. The "old" curve is the current algorithm, the "new" one is the one introduced in this PR. The graph is similar to the chain of diamonds described in the removed TODO comment (see changes). The chain length is the x axis of the graph.