Skip to content

[Clang][Driver] Add arm64e support for Swift’s "-none-macho" target triples in Clang Driver #9824

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
merged 3 commits into from
Jan 19, 2025

Conversation

kubamracek
Copy link

@kubamracek kubamracek commented Jan 13, 2025

This change moves arm64e pointer authentication flag computation from the DarwinClang toolchain to the base MachO toolchain. This makes the logic apply to all Mach-O target triples, not just Darwin ones.

Test for this in the Swift repo: swiftlang/swift#78613

rdar://141676141

…riples in Clang Driver

This change moves arm64e pointer authentication flag computation the the
DarwinClang toolchain to the base MachO toolchain. This makes the logic apply
to all Mach-O target triples, not just Darwin ones.
@kubamracek
Copy link
Author

@swift-ci please test

Copy link

@ahmedbougacha ahmedbougacha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You'll probably want this in next as well, right? I can believe that the swift test would be a bit more of a pain there; you'd probably be better off having a test here in clang/test/Driver/arch-arm64e.c anyway, with maybe just some DEFAULT-MACHO for arm64e-apple-none-macho?

@kubamracek
Copy link
Author

Test added. I also had to do a small fixup of the test as it seems to be failing -- it expected that the -target-cpu flag is right after the ptrauth flags in the output, but that's not the case. Not sure why or if this was the case in the past and it's not anymore?

@kubamracek
Copy link
Author

@swift-ci please test

@kubamracek
Copy link
Author

"next": #9846

@kubamracek
Copy link
Author

@swift-ci please smoke test macOS platform

3 similar comments
@kubamracek
Copy link
Author

@swift-ci please smoke test macOS platform

@kubamracek
Copy link
Author

@swift-ci please smoke test macOS platform

@kubamracek
Copy link
Author

@swift-ci please smoke test macOS platform

@kubamracek
Copy link
Author

@swift-ci please test macOS platform

@kubamracek kubamracek merged commit 8a823e3 into stable/20240723 Jan 19, 2025
3 checks passed
@kubamracek kubamracek deleted the mracek/none-macho-arm64e branch January 19, 2025 04:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants