[llvm] [WebAssembly] Fix operand order in performBitcastCombine (PR #190361)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Apr 4 21:45:53 PDT 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results
* 133046 tests passed
* 3060 tests skipped
* 2 tests failed
## Failed Tests
(click on a test name to see its output)
### LLVM
<details>
<summary>LLVM.CodeGen/WebAssembly/simd-bitmask.ll</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\llc.exe < C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-bitmask.ll -mattr=+simd128 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-bitmask.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\llc.exe' -mattr=+simd128
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-bitmask.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-bitmask.ll:180:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: i32.const 16
# | ^
# | <stdin>:186:2: note: 'next' match was here
# | i32.const 16
# | ^
# | <stdin>:180:9: note: previous match ended here
# | # %bb.0:
# | ^
# | <stdin>:181:1: note: non-matching line after previous match is here
# | local.get 0
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-bitmask.ll:272:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: i32.const 16
# | ^
# | <stdin>:262:2: note: 'next' match was here
# | i32.const 16
# | ^
# | <stdin>:259:9: note: previous match ended here
# | # %bb.0:
# | ^
# | <stdin>:260:1: note: non-matching line after previous match is here
# | local.get 0
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-bitmask.ll:291:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: i64.const 16
# | ^
# | <stdin>:289:2: note: 'next' match was here
# | i64.const 16
# | ^
# | <stdin>:275:9: note: previous match ended here
# | # %bb.0:
# | ^
# | <stdin>:276:1: note: non-matching line after previous match is here
# | local.get 0
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-bitmask.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | .
# | .
# | .
# | 181: local.get 0
# | 182: v128.const 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
# | 183: local.tee 2
# | 184: i8x16.eq
# | 185: i8x16.bitmask
# | 186: i32.const 16
# | next:180 !~~~~~~~~~~~ error: match on wrong line
# | 187: i32.shl
# | 188: local.get 1
# | 189: local.get 2
# | 190: i8x16.eq
# | 191: i8x16.bitmask
# | .
# | .
# | .
# | 257: manual_bitmask_v32i8: # @manual_bitmask_v32i8
# | 258: .functype manual_bitmask_v32i8 (v128, v128) -> (i32)
# | 259: # %bb.0:
# | 260: local.get 0
# | 261: i8x16.bitmask
# | 262: i32.const 16
# | next:272 !~~~~~~~~~~~ error: match on wrong line
# | 263: i32.shl
# | 264: local.get 1
# | 265: i8x16.bitmask
# | 266: i32.or
# | 267: # fallthrough-return
# | .
# | .
# | .
# | 284: i64.const 32
# | 285: i64.shl
# | 286: local.get 2
# | 287: i8x16.bitmask
# | 288: i64.extend_i32_u
# | 289: i64.const 16
# | next:291 !~~~~~~~~~~~ error: match on wrong line
# | 290: i64.shl
# | 291: i64.or
# | 292: local.get 3
# | 293: i8x16.bitmask
# | 294: i64.extend_i32_u
# | .
# | .
# | .
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1
--
```
</details>
<details>
<summary>LLVM.CodeGen/WebAssembly/simd-illegal-bitmask.ll</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\llc.exe < C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll -O3 -verify-machineinstrs -disable-wasm-fallthrough-return-opt -wasm-disable-explicit-locals -wasm-keep-registers -mattr=+simd128 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\llc.exe' -O3 -verify-machineinstrs -disable-wasm-fallthrough-return-opt -wasm-disable-explicit-locals -wasm-keep-registers -mattr=+simd128
# note: command had no output on stdout or stderr
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe' 'C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll:25:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: i32.const $push2=, 16
# | ^
# | <stdin>:31:2: note: 'next' match was here
# | i32.const $push2=, 16
# | ^
# | <stdin>:26:9: note: previous match ended here
# | # %bb.0:
# | ^
# | <stdin>:27:1: note: non-matching line after previous match is here
# | v128.const $push8=, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll:47:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: i32.const $push3=, 16
# | ^
# | <stdin>:48:2: note: 'next' match was here
# | i32.const $push3=, 16
# | ^
# | <stdin>:44:9: note: previous match ended here
# | # %bb.0:
# | ^
# | <stdin>:45:1: note: non-matching line after previous match is here
# | v128.const $push0=, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll:73:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: i32.const $push2=, 16
# | ^
# | <stdin>:65:2: note: 'next' match was here
# | i32.const $push2=, 16
# | ^
# | <stdin>:62:9: note: previous match ended here
# | # %bb.0:
# | ^
# | <stdin>:63:1: note: non-matching line after previous match is here
# | i8x16.eq $push0=, $0, $2
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll:95:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: i64.const $push3=, 16
# | ^
# | <stdin>:78:9: note: scanning from here
# | # %bb.0:
# | ^
# | <stdin>:94:2: note: possible intended match here
# | i64.const $push13=, 16
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\CodeGen\WebAssembly\simd-illegal-bitmask.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | .
# | .
# | .
# | 26: # %bb.0:
# | 27: v128.const $push8=, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32
# | 28: local.tee $push7=, $2=, $pop8
# | 29: i8x16.eq $push0=, $0, $pop7
# | 30: i8x16.bitmask $push1=, $pop0
# | 31: i32.const $push2=, 16
# | next:25 !~~~~~~~~~~~~~~~~~~~~ error: match on wrong line
# | 32: i32.shl $push3=, $pop1, $pop2
# | 33: i8x16.eq $push4=, $1, $2
# | 34: i8x16.bitmask $push5=, $pop4
# | 35: i32.or $push6=, $pop3, $pop5
# | 36: return $pop6
# | .
# | .
# | .
# | 43: .functype optimize_illegal_bitcast_v32i8_const_step_vec (v128, v128) -> (i32)
# | 44: # %bb.0:
# | 45: v128.const $push0=, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16
# | 46: i8x16.eq $push1=, $0, $pop0
# | 47: i8x16.bitmask $push2=, $pop1
# | 48: i32.const $push3=, 16
# | next:47 !~~~~~~~~~~~~~~~~~~~~ error: match on wrong line
# | 49: i32.shl $push4=, $pop2, $pop3
# | 50: v128.const $push5=, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32
# | 51: i8x16.eq $push6=, $1, $pop5
# | 52: i8x16.bitmask $push7=, $pop6
# | 53: i32.or $push8=, $pop4, $pop7
# | .
# | .
# | .
# | 60: optimize_illegal_bitcast_v32i8_non_const_vec: # @optimize_illegal_bitcast_v32i8_non_const_vec
# | 61: .functype optimize_illegal_bitcast_v32i8_non_const_vec (v128, v128, v128, v128) -> (i32)
# | 62: # %bb.0:
# | 63: i8x16.eq $push0=, $0, $2
# | 64: i8x16.bitmask $push1=, $pop0
# | 65: i32.const $push2=, 16
# | next:73 !~~~~~~~~~~~~~~~~~~~~ error: match on wrong line
# | 66: i32.shl $push3=, $pop1, $pop2
# | 67: i8x16.eq $push4=, $1, $3
# | 68: i8x16.bitmask $push5=, $pop4
# | 69: i32.or $push6=, $pop3, $pop5
# | 70: return $pop6
# | 71: end_function
# | 72: # -- End function
# | 73: .section .text.optimize_illegal_bitcast_v64i8,"",@
# | 74: .globl optimize_illegal_bitcast_v64i8 # -- Begin function optimize_illegal_bitcast_v64i8
# | 75: .type optimize_illegal_bitcast_v64i8, at function
# | 76: optimize_illegal_bitcast_v64i8: # @optimize_illegal_bitcast_v64i8
# | 77: .functype optimize_illegal_bitcast_v64i8 (v128, v128, v128, v128) -> (i64)
# | 78: # %bb.0:
# | next:95'0 X error: no match found
# | 79: v128.const $push21=, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 80: local.tee $push20=, $4=, $pop21
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 81: i8x16.eq $push0=, $0, $pop20
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 82: i8x16.bitmask $push1=, $pop0
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 83: i32.const $push2=, 16
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | 89: i64.const $push8=, 32
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~
# | 90: i64.shl $push9=, $pop7, $pop8
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 91: i8x16.eq $push10=, $2, $4
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 92: i8x16.bitmask $push11=, $pop10
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 93: i64.extend_i32_u $push12=, $pop11
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 94: i64.const $push13=, 16
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~
# | next:95'1 ? possible intended match
# | 95: i64.shl $push14=, $pop12, $pop13
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 96: i64.or $push15=, $pop9, $pop14
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 97: i8x16.eq $push16=, $3, $4
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 98: i8x16.bitmask $push17=, $pop16
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 99: i64.extend_i32_u $push18=, $pop17
# | next:95'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1
--
```
</details>
If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.
https://github.com/llvm/llvm-project/pull/190361
More information about the llvm-commits
mailing list