-
Notifications
You must be signed in to change notification settings - Fork 13.1k
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
test out experimental outlined hashmap design #60470
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
@bors try |
🔒 Merge conflict This pull request and the master branch diverged in a way that cannot be automatically merged. Please rebase on top of the latest master branch, and let the reviewer approve again. How do I rebase?Assuming
You may also read Git Rebasing to Resolve Conflicts by Drew Blessing for a short tutorial. Please avoid the "Resolve conflicts" button on GitHub. It uses Sometimes step 4 will complete without asking for resolution. This is usually due to difference between how Error message
|
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
uh... is testing out git deps not allowed? |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
You may need to either update or disable tidy, but I suspect tidy doesn't run on the try builders @bors: try |
⌛ Trying commit cdf5aa71b5599e38673b417cad27ff1dac022a7f with merge a9744339ba99b73c26c8ba5d512f11b4807a22e8... |
☀️ Try build successful - checks-travis |
this appears to not have done any benchmarking..? |
@rust-timer build a9744339ba99b73c26c8ba5d512f11b4807a22e8 |
Success: Queued a9744339ba99b73c26c8ba5d512f11b4807a22e8 with parent 758dc9a, comparison URL. |
Finished benchmarking try commit a9744339ba99b73c26c8ba5d512f11b4807a22e8 |
Ok, cool, here's the next commit to run on rust-timer. |
@bors try |
🔒 Merge conflict This pull request and the master branch diverged in a way that cannot be automatically merged. Please rebase on top of the latest master branch, and let the reviewer approve again. How do I rebase?Assuming
You may also read Git Rebasing to Resolve Conflicts by Drew Blessing for a short tutorial. Please avoid the "Resolve conflicts" button on GitHub. It uses Sometimes step 4 will complete without asking for resolution. This is usually due to difference between how Error message
|
rebased |
@bors try |
⌛ Trying commit a5fd9ef with merge 65b5892de48860c42b97e6091b09e60ae160b1a8... |
The job Click to expand the log.
I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
@bors delegate+ for trying :) |
✌️ @gankro can now approve this pull request |
☀️ Try build successful - checks-travis |
@rust-timer build 65b5892 |
Insufficient permissions to issue commands to rust-timer. |
r i p |
@rust-timer build 65b5892de48860c42b97e6091b09e60ae160b1a8 |
Success: Queued 65b5892de48860c42b97e6091b09e60ae160b1a8 with parent 08bfe16, comparison URL. |
Finished benchmarking try commit 65b5892de48860c42b97e6091b09e60ae160b1a8 |
Summary of situation: the servo devs noticed that the size_of HashMap had ballooned with the landing of hashbrown. Ultimately this was deemed an acceptable tradeoff given that hashbrown is significantly faster, and significantly reduces overall memory usage. Still, this piqued my interest, and I pursued a change to hashbrown's implementation which moved most of the fields from the body of the HashMap struct to a header at the start of hashbrown's allocation (with the exception of the often-zero-sized BuildHasher). The theoretical advantages of this are:
The theoretical disadvantages of this are:
Ok, so, here's the results I have for two different implementation strategies (based on whether the hashmap's pointer points at the header or the ctrl array): header: ctrl: My non-expert opinion of the rust-timer results indicates this is in the noise. While the pure hashmap benchmarks indicate this is slightly worse. So absent any indication that this is really useful, it seems like this approach should be abandoned. Would appreciate feedback from people who are more familiar with rust-timer results and performance tuning, though. CC @rust-lang/wg-compiler-performance @Amanieu |
Now if only we were collecting more perf counters, like cache misses, this would be more interesting. |
Thanks! Visiting this from triage -- I'm going to close this PR in favor of rust-lang/hashbrown#76 where further discussion I think should happen (since that's where the underlying work needs to happen) and there's not much activity on this PR; I suspect the conclusion that this isn't necessarily worth the implementation complexity may be accurate. If someone's interested, I would suggest running some benchmarks under cachegrind to get cache statistics (or use |
sorry, need to do this to get try builds for rust-lang/hashbrown#76
Can someone kick off whatever the perf/profiling/benchmark version of
try
is now? Want to see how this change affects rustc's perf and memory usage.(Might also need to do this a few times to test out different versions of the patch)