From ff9c41bb389fa291e0211c2e79aa3f71c3e614ac Mon Sep 17 00:00:00 2001 From: Milad Fa Date: Tue, 20 Oct 2020 16:56:14 +0000 Subject: [PATCH] [wasm-simd] Prototype load32_zero and load64_zero on BE machines Bug: v8:10713 Change-Id: I8d909ae13aecf113e1082a0f29392c169eee8aaf Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2487480 Reviewed-by: Zhi An Ng Reviewed-by: Bill Budge Commit-Queue: Milad Fa Cr-Commit-Position: refs/heads/master@{#70688} --- src/compiler/wasm-compiler.cc | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/compiler/wasm-compiler.cc b/src/compiler/wasm-compiler.cc index f97eb97343..ee8089cbf5 100644 --- a/src/compiler/wasm-compiler.cc +++ b/src/compiler/wasm-compiler.cc @@ -3961,6 +3961,20 @@ Node* WasmGraphBuilder::LoadTransformBigEndian( result = graph()->NewNode(mcgraph()->machine()->I64x2Splat(), result); break; } + case LoadTransformation::kS128Load32Zero: { + result = graph()->NewNode(mcgraph()->machine()->S128Zero()); + result = graph()->NewNode( + mcgraph()->machine()->I32x4ReplaceLane(0), result, + LoadMem(type, memtype, index, offset, alignment, position)); + break; + } + case LoadTransformation::kS128Load64Zero: { + result = graph()->NewNode(mcgraph()->machine()->S128Zero()); + result = graph()->NewNode( + mcgraph()->machine()->I64x2ReplaceLane(0), result, + LoadMem(type, memtype, index, offset, alignment, position)); + break; + } default: UNREACHABLE(); }