Commit f9dc259a authored by Ng Zhi An's avatar Ng Zhi An Committed by Commit Bot

[wasm-simd] Expect fused results on Liftoff

FMA tests that are running on Liftoff can use fused results, since the
tests will fall back to TurboFan.

Bug: v8:9415
Change-Id: I02edea5ce1447263f7bc7574573418b0055aef8f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2063202Reviewed-by: 's avatarDeepti Gandluri <gdeepti@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#66438}
parent ff89c6bc
......@@ -376,12 +376,14 @@ static constexpr Vector<const FMOperation<T>> qfms_vector() {
return ArrayVector(qfms_array<T>);
}
// Fused results only when fma3 feature is enabled, and running on TurboFan.
// Fused results only when fma3 feature is enabled, and running on TurboFan or
// Liftoff (which can fall back to TurboFan if FMA is not implemented).
bool ExpectFused(ExecutionTier tier) {
#ifdef V8_TARGET_ARCH_X64
return CpuFeatures::IsSupported(FMA3) && (tier == ExecutionTier::kTurbofan);
return CpuFeatures::IsSupported(FMA3) &&
(tier == ExecutionTier::kTurbofan || tier == ExecutionTier::kLiftoff);
#else
return (tier == ExecutionTier::kTurbofan);
return (tier == ExecutionTier::kTurbofan || tier == ExecutionTier::kLiftoff);
#endif
}
#endif // V8_TARGET_ARCH_X64 || V8_TARGET_ARCH_ARM64
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment