-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Stop emitting drop loops for every array length #134297
base: master
Are you sure you want to change the base?
Conversation
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
…<try> Stop emitting drop loops for every array length We can just unsize the array to a slice and drop that instead, reusing the same slice loop for every array length. As part of this (and how I originally noticed this), use `PtrMetadata` instead of `Len` for the slice length, for another step closer to being able to remove `Rvalue::Len`. Demonstration that yes, every slice length gets its own loop today: <https://rust.godbolt.org/z/5EsPjPWv4>
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
💔 Test failed - checks-actions |
We can just unsize the array to a slice and drop that instead, reusing the same loop. As part of this (and how I originally noticed this), use `PtrMetadata` instead of `Len` for the slice length, for another step closer to being able to remove `Rvalue::Len`.
f6cd47a
to
aac57cf
Compare
The job Click to see the possible cause of the failure (guessed by this bot)
|
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
…<try> Stop emitting drop loops for every array length We can just unsize the array to a slice and drop that instead, reusing the same slice loop for every array length. As part of this (and how I originally noticed this), use `PtrMetadata` instead of `Len` for the slice length, for another step closer to being able to remove `Rvalue::Len`. Demonstration that yes, every slice length gets its own loop today: <https://rust.godbolt.org/z/5EsPjPWv4>
The job Click to see the possible cause of the failure (guessed by this bot)
|
💔 Test failed - checks-actions |
(These failures within opt-dist running rustc-perf aren't super clear... I'll try to see how to improve that.) |
We can just unsize the array to a slice and drop that instead, reusing the same slice loop for every array length.
As part of this (and how I originally noticed this), use
PtrMetadata
instead ofLen
for the slice length, for another step closer to being able to removeRvalue::Len
.Demonstration that yes, every slice length gets its own loop today: https://rust.godbolt.org/z/5EsPjPWv4