Commit 51067cc2 authored by Ng Zhi An's avatar Ng Zhi An Committed by Commit Bot

[wasm-simd][liftoff] Fix spills of S128 values on ARM

Add a case for kWasmS128 in Spill. We encounter this in the
wasm-trace-memory-liftoff test, but that test was skipped on ARM and
ARM64 due to insufficient implementation of Liftoff on those archs. But
with recent changes, they are now capable of running this particular
test, so we enable it.

Drive-by fix for incorrect size used in vld1 for filling S128 values.

Bug: v8:9909
Change-Id: I8addd06ba3c9a40364e432180cd5dbc48debca23
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2007901
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Reviewed-by: 's avatarClemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#65904}
parent 5b981d35
......@@ -620,6 +620,13 @@ void LiftoffAssembler::Spill(int offset, LiftoffRegister reg, ValueType type) {
case kWasmF64:
vstr(reg.fp(), dst);
break;
case kWasmS128: {
UseScratchRegisterScope temps(this);
Register addr = liftoff::CalculateActualAddress(this, &temps, dst.rn(),
no_reg, dst.offset());
vst1(Neon8, NeonListOperand(reg.low_fp(), 2), NeonMemOperand(addr));
break;
}
default:
UNREACHABLE();
}
......@@ -678,7 +685,7 @@ void LiftoffAssembler::Fill(LiftoffRegister reg, int offset, ValueType type) {
UseScratchRegisterScope temps(this);
Register addr = liftoff::CalculateActualAddress(this, &temps, slot.rn(),
no_reg, slot.offset());
vld1(Neon64, NeonListOperand(reg.low_fp(), 2), NeonMemOperand(addr));
vld1(Neon8, NeonListOperand(reg.low_fp(), 2), NeonMemOperand(addr));
break;
}
default:
......
......@@ -37,11 +37,11 @@
'fail/modules-skip*': [SKIP],
}], # ALWAYS
# Liftoff is currently only sufficiently implemented on x64 and ia32.
# Liftoff is currently only sufficiently implemented on x64, ia32, arm, arm64.
# TODO(clemensb): Implement on all other platforms (crbug.com/v8/6600).
['arch != x64 and arch != ia32', {
['arch != x64 and arch != ia32 and arch != arm64 and arch != arm', {
'wasm-trace-memory-liftoff': [SKIP],
}], # arch != x64 and arch != ia32
}], # arch != x64 and arch != ia32 and arch != arm64 and arch != arm
['variant == code_serializer', {
# TODO(yangguo): Code serializer output is incompatible with all message
......
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