-
Notifications
You must be signed in to change notification settings - Fork 15.4k
[clang][PAC] ptrauth_qualifier and ptrauth_intrinsic should only be available on Darwin #153912
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
Merged
ojhunt
merged 8 commits into
main
from
users/ojhunt/de-and-re-featurify-ptrauth-qualifier-and-intrinsics
Aug 18, 2025
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
ea73192
[clang][PAC] Make ptrauth_qualifier and ptrauth_intrinsic Darwin only…
ojhunt ee8c1ae
Add release note
ojhunt b1b2de3
Update clang/docs/ReleaseNotes.rst
ojhunt bade8f3
Revert addition of a new declaration requirement
ojhunt 3316f38
remove added lines
ojhunt e993782
Move release note
ojhunt 9cb052c
Merge branch 'main' into users/ojhunt/de-and-re-featurify-ptrauth-qua…
ojhunt a78ae13
Merge branch 'main' into users/ojhunt/de-and-re-featurify-ptrauth-qua…
ojhunt File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
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.
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.
Did we synchronize with GCC here (or does gcc not support this feature at all yet?)
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.
I don't believe gcc has any support as yet? I recall talking to one gcc person in Sofia but it didn't sound like it's high priority.
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.
Ok, so there's an existing
__ARM_FEATURE_PAUTHbut that does not cover the language features.Naming-wise do we want something along the lines of
__ARM_FEATURE_PAUTH_LANG_SUPPORT__?__ARM_FEATURE_PAUTHonly indicates the target supports the features -- gcc doesn't provide anything more than that afaictThere 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.
(we have __ARM_FEATURE_PAUTH already)
Uh oh!
There was an error while loading. Please reload this page.
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
__ARM_FEATURE_PAC_DEFAULT, apparently. But this seems fairly target-related.I'm fine with
__PTRAUTH__(or__PTRAUTH)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.
I think @AaronBallman had an opinion on the
__suffix - I am absolutely indifferent here and as demonstrated am terrible at names :DThere 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.
I'm happy with
__PTRAUTH__; do we want it to expand to a particular value so we can change the value to have the macro mean a different feature set is enabled?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.
I think the complexity of the ptrauth abi surface area means that I don't think any single value can really represent it - there's significant variation for us in userspace vs kernel vs other constrained environments vs what the linux folk are doing.
I think any dev who does need to work at this level will need to be directly detecting each single mode that is active