Skip to content
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

Enable outline-atomics by default and provide a cfg to disable it #25

Closed
taiki-e opened this issue Aug 4, 2022 · 0 comments · Fixed by #57
Closed

Enable outline-atomics by default and provide a cfg to disable it #25

taiki-e opened this issue Aug 4, 2022 · 0 comments · Fixed by #57

Comments

@taiki-e
Copy link
Owner

taiki-e commented Aug 4, 2022

Since the cargo features are additive, a dependency may enable outline-atomics even if the user does not want to enable it.

The correct approach here seems to be to enable outline-atomics by default and provide a cfg to force it to be disabled.

bors bot added a commit that referenced this issue Dec 25, 2022
57: Enable outline-atomics by default and provide cfg to disable it r=taiki-e a=taiki-e

This enables `outline-atomics` feature by default and provides `portable_atomic_no_outline_atomics` cfg to disable it.

(outline-atomics enables several optimizations on x86_64 and aarch64. See [this list](#10 (comment)) for details.)

It has previously been pointed out that due to the nature of the cargo feature, controlling this based on the cargo feature does not work well. Since this release, `outline-atomics` feature has been no-op, and outline-atomics is enabled by default.

Note: outline-atomics in portable-atomics is currently for 128-bit atomics. outline-atomics for atomics with other sizes is controlled by LLVM's `outline-atomics` target feature.

Closes #25

Co-authored-by: Taiki Endo <te316e89@gmail.com>
bors bot added a commit that referenced this issue Dec 25, 2022
57: Enable outline-atomics by default and provide cfg to disable it r=taiki-e a=taiki-e

This enables `outline-atomics` feature by default and provides `portable_atomic_no_outline_atomics` cfg to disable it.

(outline-atomics enables several optimizations on x86_64 and aarch64. See [this list](#10 (comment)) for details.)

It has previously been pointed out that due to the nature of the cargo feature, controlling this based on the cargo feature does not work well. Since this release, `outline-atomics` feature has been no-op, and outline-atomics is enabled by default.

Note: outline-atomics in portable-atomics is currently for 128-bit atomics. outline-atomics for atomics with other sizes is controlled by LLVM's `outline-atomics` target feature.

Closes #25

Co-authored-by: Taiki Endo <te316e89@gmail.com>
@bors bors bot closed this as completed in 78d9ef1 Dec 25, 2022
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 a pull request may close this issue.

1 participant