-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
Shrink ast::{Generics,Impl,Block}
#101472
Shrink ast::{Generics,Impl,Block}
#101472
Conversation
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
⌛ Trying commit 57eb7e7 with merge 0fe233aee325ca40218db024909c8b834c97dba0... |
The job Click to see the possible cause of the failure (guessed by this bot)
|
💔 Test failed - checks-actions |
The job Click to see the possible cause of the failure (guessed by this bot)
|
@@ -2440,7 +2440,7 @@ pub struct ForeignMod { | |||
|
|||
#[derive(Clone, Encodable, Decodable, Debug)] | |||
pub struct EnumDef { | |||
pub variants: Vec<Variant>, | |||
pub variants: Box<[Variant]>, |
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.
Maybe we could use std::boxed::ThinBox
or something similar to further reduce the size from 16
to 8
bytes? By storing the slice size on the heap.
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.
There is also thin_vec::ThinVec
, which I introduced to the compiler in #100869. Unfortunately, getting any of these kinds of changes to show a clear performance benefit has been hard.
This one seems unlikely to produce any wins. |
r? @ghost