Skip to content

Avoid enabling AVX when rustc isn't using it #62

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 1 commit into from
Feb 10, 2025
Merged

Conversation

kornelski
Copy link

Microsoft's documentation says that /arch:SSE4.2 is a supported option, but MSVC 2019 doesn't have it. /arch:AVX can't be safely set as a fallback, because it affects ABI. This PR enables AVX in C only when Rust is building with target-features+avx.

Fixes rust-lang/flate2-rs#451

This is needed for ABI to match
@kornelski kornelski merged commit 38d3db6 into gcc.amd64 Feb 10, 2025
9 checks passed
@kornelski kornelski deleted the cpu-detect-rs branch February 10, 2025 14:40
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.

1 participant