-
Notifications
You must be signed in to change notification settings - Fork 13.4k
compiler: set Apple frame pointers by architecture #141797
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
compiler: set Apple frame pointers by architecture #141797
Conversation
These commits modify compiler targets. |
This mostly affects An obvious alternative to this PR is to make the default frame-pointer setting something arch-dependent instead. |
This comment has been minimized.
This comment has been minimized.
6822314
to
57b04e7
Compare
This comment has been minimized.
This comment has been minimized.
57b04e7
to
cca230a
Compare
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.
To be clear, the affected targets as far as I can tell are:
aarch64-apple-watchos
(likely a correct change, though might not be, watchOS is kinda weird sometimes)armv7s-apple-ios
armv7k-apple-watchos
arm64_32-apple-watchos
x86_64-apple-darwin
x86_64h-apple-darwin
x86_64-apple-ios-macabi
x86_64-apple-ios
x86_64-apple-tvos
x86_64-apple-watchos-sim
i686-apple-darwin
i386-apple-ios
Are all of these intentional?
An obvious alternative to this PR is to make the default frame-pointer setting something arch-dependent instead.
Do you know what Clang's logic is? I'd be much more comfortable following that, whatever it is.
Yes. Previously, they would default to full frame pointers, which seems strictly worse for codegen on the more binary-size-constrained targets. |
It seems on x86 platforms, clang indeed uses full frame pointers. Clang will also reject |
@madsmtm Part of my reasoning, aside from it being a simplifying assumption, is that since |
Anyways, that said, I'm equally happy to just make the value of |
Yeah, I'd prefer that (so that we'd only be changing the value for |
cca230a
to
8d4031e
Compare
I have implemented the change mentioned. |
This comment has been minimized.
This comment has been minimized.
Apple targets can now overriding this configuration and instead use the default based on their architecture, which means aarch64 targets now have less frame pointers in leaf functions.
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.
Thanks! Feel free to r=me after the test change has been reverted:
@bors delegate+ rollup
8d4031e
to
b25aa26
Compare
literally was just pushing that :^) @bors r=madsmtm |
…ointers-but-not-that-much, r=madsmtm compiler: set Apple frame pointers by architecture All Apple targets stop overriding this configuration and instead use the default base of FramePointer::NonLeaf, which means some Apples will have less frame pointers in leaf functions. r? `@madsmtm` cc `@thomcc`
Rollup of 8 pull requests Successful merges: - #137992 (Stabilise `os_string_pathbuf_leak`) - #141558 (Limit the size of cgu names when using the `-Zhuman-readable-cgu-name…) - #141797 (compiler: set Apple frame pointers by architecture) - #141857 (coretests: move float tests from num to floats module and use a more flexible macro to generate them) - #142045 (Make obligation cause code suggestions verbose) - #142076 (Check documentation of bootstrap in PR CI) - #142110 (Add solaris targets to build-manifest) - #142131 (Make cast suggestions verbose) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of #141797 - workingjubilee:apple-likes-frame-pointers-but-not-that-much, r=madsmtm compiler: set Apple frame pointers by architecture All Apple targets stop overriding this configuration and instead use the default base of FramePointer::NonLeaf, which means some Apples will have less frame pointers in leaf functions. r? ``@madsmtm`` cc ``@thomcc``
All Apple targets stop overriding this configuration and instead use the default base of FramePointer::NonLeaf, which means some Apples will have less frame pointers in leaf functions.
r? @madsmtm
cc @thomcc