[wasm-simd][x64] Optimize I8x16Shuffle if one input is S128Zero
If b is S128Zero, Shuffle(a,b,s) can be optimized to Swizzle(a,s). By setting s[i] to 0x80, we can avoid access b. If a is S128Zero, we can swap a and b first. If one input of I8x16Shuffle is S128Zero, this patch can save ~60% instructions(7 of 12), and more than 30% improvement is observed in local microbenchmarks. Change-Id: I5953fa9064e01203cd4cf423c55dd5ed33cad57e Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3544992Reviewed-by: Deepti Gandluri <gdeepti@chromium.org> Commit-Queue: Jie Pan <jie.pan@intel.com> Cr-Commit-Position: refs/heads/main@{#80623}
Showing
Please
register
or
sign in
to comment