x64: Lower SIMD requirement to SSE2#6625
Merged
fitzgen merged 1 commit intoJun 22, 2023
Merged
Conversation
All instructions in Cranelift now have lowerings for SSE2 as a baseline, even if they're not exactly the speediest things in the world. This enables lowering the baseline required for the SIMD proposal for WebAssembly to SSE2, the base features set of x86_64. Lots of tests were updated here to remove explicit `has_foo=false` annotations as they no longer have any effect. Additionally fuzzing has been updated to enable disabling `sse3` and `ssse3` which will help stress-test all previously-added lowerings.
Member
Author
|
With @fitzgen's excellent idea of actually testing these on somewhat real hardware I ran the test suite through QEMU with (I don't have actual old hardware to test on myeslf) |
alexcrichton
added a commit
to alexcrichton/wasmtime
that referenced
this pull request
Jun 22, 2023
This commit removes a setting for Cranelift which I've found a bit confusing historically and I think is no longer necessary. The setting is currently documented as enabling SIMD instructions, but that only sort of works for the x64 backend and none of the other backends look at it. Historically this was used to flag to Cranelift that a higher x64 baseline feature set is required for codegen but as of bytecodealliance#6625 that's no longer necessary. Otherwise it seems more Cranelift-like nowadays to say that vector instructions generate SIMD instructions where non-vector instructions probably don't, but may still depending on activated CPU features. In that sense I'm not sure if a dedicated `enable_simd` setting is still motivated, so this PR removes it. This renames some features in the x86 backend such as `use_avx_simd` to `use_avx` since the `_simd` part is no longer part of the computation now that `enable_simd` is gone.
github-merge-queue Bot
pushed a commit
that referenced
this pull request
Jun 22, 2023
This commit removes a setting for Cranelift which I've found a bit confusing historically and I think is no longer necessary. The setting is currently documented as enabling SIMD instructions, but that only sort of works for the x64 backend and none of the other backends look at it. Historically this was used to flag to Cranelift that a higher x64 baseline feature set is required for codegen but as of #6625 that's no longer necessary. Otherwise it seems more Cranelift-like nowadays to say that vector instructions generate SIMD instructions where non-vector instructions probably don't, but may still depending on activated CPU features. In that sense I'm not sure if a dedicated `enable_simd` setting is still motivated, so this PR removes it. This renames some features in the x86 backend such as `use_avx_simd` to `use_avx` since the `_simd` part is no longer part of the computation now that `enable_simd` is gone.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
All instructions in Cranelift now have lowerings for SSE2 as a baseline, even if they're not exactly the speediest things in the world. This enables lowering the baseline required for the SIMD proposal for WebAssembly to SSE2, the base features set of x86_64. Lots of tests were updated here to remove explicit
has_foo=falseannotations as they no longer have any effect.Additionally fuzzing has been updated to enable disabling
sse3andssse3which will help stress-test all previously-added lowerings.