Skip to content

Eliminate build.rs-generated Aarch64 atomic macros #951

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 8 commits into from
Jun 13, 2025

Conversation

qinghon
Copy link
Contributor

@qinghon qinghon commented Jun 10, 2025

Replace build.rs Rust generation with macros, using the unstable ${concat(...)}.

Fixes: #947

@tgross35
Copy link
Contributor

Regarding #947 (comment): we should make use of the unstable ${concat(...)} (rust-lang/rust#124225). This just means writing the macro in source rather than generating it in the build script and include!ing it there

include!(concat!(env!("OUT_DIR"), "/outlined_atomics.rs"));
.

@qinghon
Copy link
Contributor Author

qinghon commented Jun 11, 2025

@tgross35 Is it like this now?

Copy link
Contributor

@tgross35 tgross35 left a comment

Choose a reason for hiding this comment

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

Looks good, thanks! Just two small nits

@tgross35 tgross35 changed the title fix aarch64 outlined atomics codegen bug Eliminate build.rs-generated Aarch64 atomic macros Jun 11, 2025
@qinghon qinghon requested a review from tgross35 June 11, 2025 07:32
@tgross35
Copy link
Contributor

Thanks for the changes, I'll double check this tomorrow and merge it.

Copy link
Contributor

@tgross35 tgross35 left a comment

Choose a reason for hiding this comment

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

LGTM, thank you!

@tgross35 tgross35 merged commit 2f01db9 into rust-lang:master Jun 13, 2025
35 checks passed
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.

[BUG] Compile fail on aarch64 musl when setting -Zfmt-debug=none
2 participants