• Zhi An Ng's avatar
    [wasm-simd][ia32] Optimize integer splats of constant 0 · cc68080f
    Zhi An Ng authored
    Integer splats (especially for sizes < 32-bits) does not directly
    translate to a single instruction on ia32. We can do better for special
    values, like 0, which can be lowered to `eor dst dst`. We do this check
    in the instruction selector, and emit a special opcode kX64S128Zero.
    
    Also add a unittest to verify this optimization, and necessary
    raw-assembler methods for the test.
    
    Bug: v8:11093
    Change-Id: Icfebef06a5ecf49619ea54f31a5296094fb53ff2
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2516300Reviewed-by: 's avatarTobias Tebbi <tebbi@chromium.org>
    Commit-Queue: Zhi An Ng <zhin@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#71024}
    cc68080f
instruction-selector-ia32-unittest.cc 28.6 KB