[llvm] [AArch64][ISel] Adjust shouldBeAdjustedToZero to also accept one-use cases for -1 (PR #199439)
via llvm-commits
llvm-commits at lists.llvm.org
Mon May 25 09:38:00 PDT 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results
* 135012 tests passed
* 3322 tests skipped
* 2 tests failed
## Failed Tests
(click on a test name to see its output)
### LLVM
<details>
<summary>LLVM.Transforms/LoopStrengthReduce/AArch64/postidx-load.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\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll -mtriple=aarch64-none-elf | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\llc.exe' -mtriple=aarch64-none-elf
# 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\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll:10:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: cmp x1, #1
# | ^
# | <stdin>:8:20: note: scanning from here
# | // %bb.0: // %entry
# | ^
# | <stdin>:9:2: note: possible intended match here
# | cmp x1, #0
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll:58:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: cmp x1, #1
# | ^
# | <stdin>:39:20: note: scanning from here
# | // %bb.0: // %entry
# | ^
# | <stdin>:40:2: note: possible intended match here
# | cmp x1, #0
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll:106:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: cmp x1, #1
# | ^
# | <stdin>:71:28: note: scanning from here
# | movi d0, #0000000000000000
# | ^
# | <stdin>:72:2: note: possible intended match here
# | cmp x1, #0
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll:151:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: cmp x1, #1
# | ^
# | <stdin>:99:28: note: scanning from here
# | movi d0, #0000000000000000
# | ^
# | <stdin>:100:2: note: possible intended match here
# | cmp x1, #0
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\postidx-load.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | 1: .file "<stdin>"
# | 2: .text
# | 3: .globl i32_initially_postidx // -- Begin function i32_initially_postidx
# | 4: .p2align 2
# | 5: .type i32_initially_postidx, at function
# | 6: i32_initially_postidx: // @i32_initially_postidx
# | 7: .cfi_startproc
# | 8: // %bb.0: // %entry
# | next:10'0 X error: no match found
# | 9: cmp x1, #0
# | next:10'0 ~~~~~~~~~~~~
# | next:10'1 ? possible intended match
# | 10: b.le .LBB0_5
# | next:10'0 ~~~~~~~~~~~~~~
# | 11: // %bb.1: // %for.body.preheader
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 12: mov w8, wzr
# | next:10'0 ~~~~~~~~~~~~~
# | 13: .LBB0_2: // %for.body
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~
# | 14: // =>This Inner Loop Header: Depth=1
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | 34: .globl i32_initially_offset // -- Begin function i32_initially_offset
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 35: .p2align 2
# | next:10'0 ~~~~~~~~~~~~
# | 36: .type i32_initially_offset, at function
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 37: i32_initially_offset: // @i32_initially_offset
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~
# | 38: .cfi_startproc
# | 39: // %bb.0: // %entry
# | next:58'0 X error: no match found
# | 40: cmp x1, #0
# | next:58'0 ~~~~~~~~~~~~
# | next:58'1 ? possible intended match
# | 41: b.le .LBB1_5
# | next:58'0 ~~~~~~~~~~~~~~
# | 42: // %bb.1: // %for.body.preheader
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 43: mov w8, wzr
# | next:58'0 ~~~~~~~~~~~~~
# | 44: .LBB1_2: // %for.body
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~
# | 45: // =>This Inner Loop Header: Depth=1
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | 66: .p2align 2
# | next:58'0 ~~~~~~~~~~~~
# | 67: .type float_initially_postidx, at function
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 68: float_initially_postidx: // @float_initially_postidx
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~
# | 69: .cfi_startproc
# | 70: // %bb.0: // %entry
# | 71: movi d0, #0000000000000000
# | next:106'0 X error: no match found
# | 72: cmp x1, #0
# | next:106'0 ~~~~~~~~~~~~
# | next:106'1 ? possible intended match
# | 73: b.le .LBB2_3
# | next:106'0 ~~~~~~~~~~~~~~
# | 74: .LBB2_1: // %for.body
# | next:106'0 ~~~~~~~~~~~~~~~~~~~~~~
# | 75: // =>This Inner Loop Header: Depth=1
# | next:106'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 76: ldr s1, [x0], #4
# | next:106'0 ~~~~~~~~~~~~~~~~~~
# | 77: fadd s0, s0, s1
# | next:106'0 ~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | 94: .p2align 2
# | next:106'0 ~~~~~~~~~~~~
# | 95: .type float_initially_offset, at function
# | next:106'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 96: float_initially_offset: // @float_initially_offset
# | next:106'0 ~~~~~~~~~~~~~~~~~~~~~~~
# | 97: .cfi_startproc
# | 98: // %bb.0: // %entry
# | 99: movi d0, #0000000000000000
# | next:151'0 X error: no match found
# | 100: cmp x1, #0
# | next:151'0 ~~~~~~~~~~~~
# | next:151'1 ? possible intended match
# | 101: b.le .LBB3_3
# | next:151'0 ~~~~~~~~~~~~~~
# | 102: .LBB3_1: // %for.body
# | next:151'0 ~~~~~~~~~~~~~~~~~~~~~~
# | 103: // =>This Inner Loop Header: Depth=1
# | next:151'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 104: ldr s1, [x0], #4
# | next:151'0 ~~~~~~~~~~~~~~~~~~
# | 105: fadd s0, s0, s1
# | next:151'0 ~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1
--
```
</details>
<details>
<summary>LLVM.Transforms/LoopStrengthReduce/AArch64/pr53625.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\Transforms\LoopStrengthReduce\AArch64\pr53625.ll -mtriple=aarch64-unknown-unknown | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\pr53625.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\llc.exe' -mtriple=aarch64-unknown-unknown
# 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\Transforms\LoopStrengthReduce\AArch64\pr53625.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\pr53625.ll:10:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: cmp w0, #1
# | ^
# | <stdin>:8:20: note: scanning from here
# | // %bb.0: // %entry
# | ^
# | <stdin>:9:2: note: possible intended match here
# | cmp w0, #0
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\pr53625.ll:58:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: cmp w0, #1
# | ^
# | <stdin>:36:20: note: scanning from here
# | // %bb.0: // %entry
# | ^
# | <stdin>:37:2: note: possible intended match here
# | cmp w0, #0
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\pr53625.ll:128:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: cmp w0, #1
# | ^
# | <stdin>:74:20: note: scanning from here
# | // %bb.0: // %entry
# | ^
# | <stdin>:75:2: note: possible intended match here
# | cmp w0, #0
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\AArch64\pr53625.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | 1: .file "<stdin>"
# | 2: .text
# | 3: .globl test // -- Begin function test
# | 4: .p2align 2
# | 5: .type test, at function
# | 6: test: // @test
# | 7: .cfi_startproc
# | 8: // %bb.0: // %entry
# | next:10'0 X error: no match found
# | 9: cmp w0, #0
# | next:10'0 ~~~~~~~~~~~~
# | next:10'1 ? possible intended match
# | 10: b.le .LBB0_4
# | next:10'0 ~~~~~~~~~~~~~~
# | 11: // %bb.1: // %for.body.preheader
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 12: mov w8, w0
# | next:10'0 ~~~~~~~~~~~~
# | 13: .LBB0_2: // %for.body
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~
# | 14: // =>This Inner Loop Header: Depth=1
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | 31: .globl IVIncHoist_not_all_user_in_header // -- Begin function IVIncHoist_not_all_user_in_header
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 32: .p2align 2
# | next:10'0 ~~~~~~~~~~~~
# | 33: .type IVIncHoist_not_all_user_in_header, at function
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 34: IVIncHoist_not_all_user_in_header: // @IVIncHoist_not_all_user_in_header
# | next:10'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 35: .cfi_startproc
# | 36: // %bb.0: // %entry
# | next:58'0 X error: no match found
# | 37: cmp w0, #0
# | next:58'0 ~~~~~~~~~~~~
# | next:58'1 ? possible intended match
# | 38: b.le .LBB1_5
# | next:58'0 ~~~~~~~~~~~~~~
# | 39: // %bb.1: // %for.body.preheader
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 40: mov x8, xzr
# | next:58'0 ~~~~~~~~~~~~~
# | 41: mov w9, w0
# | next:58'0 ~~~~~~~~~~~~
# | 42: add x10, x1, #4
# | next:58'0 ~~~~~~~~~~~~~~~~~
# | .
# | .
# | .
# | 69: .globl negative_test_type_is_struct // -- Begin function negative_test_type_is_struct
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 70: .p2align 2
# | next:58'0 ~~~~~~~~~~~~
# | 71: .type negative_test_type_is_struct, at function
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 72: negative_test_type_is_struct: // @negative_test_type_is_struct
# | next:58'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 73: .cfi_startproc
# | 74: // %bb.0: // %entry
# | next:128'0 X error: no match found
# | 75: cmp w0, #0
# | next:128'0 ~~~~~~~~~~~~
# | next:128'1 ? possible intended match
# | 76: b.le .LBB2_4
# | next:128'0 ~~~~~~~~~~~~~~
# | 77: // %bb.1: // %for.body.preheader
# | next:128'0 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# | 78: mov w8, w0
# | next:128'0 ~~~~~~~~~~~~
# | 79: .LBB2_2: // %for.body
# | next:128'0 ~~~~~~~~~~~~~~~~~~~~~~
# | 80: // =>This Inner Loop Header: Depth=1
# | next:128'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/199439
More information about the llvm-commits
mailing list