x64: Lower SIMD requirement to SSE4.1 from SSE4.2 (#6206)

Cranelift only has one instruction SIMD which depends on SSE4.2 so this
commit adds a lowering rule for `pcmpgtq` which doesn't use SSE4.2 and
enables lowering the baseline requirement for SIMD support from SSE4.2
to SSE4.1.

The `has_sse42` setting is no longer enabled by default for Cranelift.
Additionally `enable_simd` no longer requires `has_sse42` on x64.
Finally the fuzz-generator for Wasmtime codegen settings now enables
flipping the `has_sse42` setting instead of unconditionally setting it
to `true`.

The specific lowering for `pcmpgtq` is copied from LLVM's lowering of
this instruction.
This commit is contained in:
Alex Crichton
2023-04-14 12:24:43 -05:00
committed by GitHub
parent 26f9ce02bc
commit 2d25db047f
8 changed files with 62 additions and 15 deletions

View File

@@ -38,7 +38,7 @@ fn define_settings(shared: &SettingGroup) -> SettingGroup {
"has_sse42",
"Has support for SSE4.2.",
"SSE4.2: CPUID.01H:ECX.SSE4_2[bit 20]",
true,
false,
);
let has_avx = settings.add_bool(
"has_avx",