[llvm] [SCEV] Preserve nuw on scaled recurrence start values. (PR #227458)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 29 17:46:40 PDT 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results
* 142956 tests passed
* 3386 tests skipped
* 2 tests failed
## Failed Tests
(click on a test name to see its output)
### LLVM
<details>
<summary>LLVM.Analysis/ScalarEvolution/scaled-start-use-flags.ll</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\opt.exe -passes='print<scalar-evolution>' -disable-output C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll 2>&1 | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\opt.exe' '-passes=print<scalar-evolution>' -disable-output 'C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll'
# 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\Analysis\ScalarEvolution\scaled-start-use-flags.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll:10:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: --> {(%a * %b),+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | ^
# | <stdin>:5:30: note: scanning from here
# | %index = mul nuw i32 %iv, %b
# | ^
# | <stdin>:6:9: note: possible intended match here
# | --> {(%a * %b)<u nuw>,+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll:52:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: --> {(%a * %b),+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | ^
# | <stdin>:24:30: note: scanning from here
# | %index = mul nuw i32 %iv, %b
# | ^
# | <stdin>:25:9: note: possible intended match here
# | --> {(%a * %b)<u nuw>,+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll:95:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: --> {(3 * %a),+,3}<nuw><%loop> U: full-set S: full-set Exits: ((3 * ((((-3 * %a) + (-1 * (1 umin ((-3 * %a) + ((3 * %a) umax %n))))<nuw><nsw> + ((3 * %a) umax %n)) /u 3) + (1 umin ((-3 * %a) + ((3 * %a) umax %n)))))<u nuw> + (3 * %a))<u nuw> LoopDispositions: { %loop: Computable }
# | ^
# | <stdin>:43:29: note: scanning from here
# | %index = mul nuw i32 %iv, 3
# | ^
# | <stdin>:44:10: note: possible intended match here
# | --> {(3 * %a)<u nuw>,+,3}<nuw><%loop> U: full-set S: full-set Exits: ((3 * ((((-3 * %a) + (-1 * (1 umin ((-3 * %a) + ((3 * %a) umax %n))))<nuw><nsw> + ((3 * %a) umax %n)) /u 3) + (1 umin ((-3 * %a) + ((3 * %a) umax %n)))))<u nuw> + (3 * %a))<u nuw> LoopDispositions: { %loop: Computable }
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll:133:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: --> {(%a * %b),+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | ^
# | <stdin>:63:2: note: 'next' match was here
# | --> {(%a * %b),+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | ^
# | <stdin>:60:30: note: previous match ended here
# | %index = mul nuw i32 %iv, %b
# | ^
# | <stdin>:61:1: note: non-matching line after previous match is here
# | --> {(%a * %b)<u nuw>,+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\Analysis\ScalarEvolution\scaled-start-use-flags.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | 1: Printing analysis 'Scalar Evolution Analysis' for function 'scaled_nuw':
# | 2: Classifying expressions for: @scaled_nuw
# | 3: %iv = phi i32 [ %a, %ph ], [ %iv.next, %loop ]
# | 4: --> {%a,+,1}<nuw><%loop> U: full-set S: full-set Exits: (-1 + %n) LoopDispositions: { %loop: Computable }
# | 5: %index = mul nuw i32 %iv, %b
# | next:10'0 { search range start (exclusive)
# | next:10'1 error: no match found in search range
# | 6: --> {(%a * %b)<u nuw>,+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | next:10'2 ? possible intended match
# | 7: %wide = zext i32 %index to i64
# | 8: --> {(zext i32 (%a * %b)<u nuw> to i64),+,(zext i32 %b to i64)}<nuw><%loop> U: [0,-4294967295) S: [0,-4294967295) Exits: ((zext i32 (%a * %b)<u nuw> to i64) + ((zext i32 (-1 + (-1 * %a) + %n) to i64) * (zext i32 %b to i64))<u nuw>)<u nuw> LoopDispositions: { %loop: Computable }
# | 9: %p = getelementptr i8, ptr %dst, i64 %wide
# | 10: --> {((zext i32 (%a * %b)<u nuw> to i64) + %dst),+,(zext i32 %b to i64)}<nw><%loop> U: full-set S: full-set Exits: ((zext i32 (%a * %b)<u nuw> to i64) + ((zext i32 (-1 + (-1 * %a) + %n) to i64) * (zext i32 %b to i64)) + %dst) LoopDispositions: { %loop: Computable }
# | 11: %iv.next = add nuw i32 %iv, 1
# | 12: --> {(1 + %a),+,1}<nuw><%loop> U: full-set S: full-set Exits: %n LoopDispositions: { %loop: Computable }
# | 13: %bare = mul i32 %a, %b
# | 14: --> (%a * %b) U: full-set S: full-set
# | 15: Determining loop execution counts for: @scaled_nuw
# | 16: Loop %loop: backedge-taken count is (-1 + (-1 * %a) + %n)
# | 17: Loop %loop: constant max backedge-taken count is i32 -1
# | 18: Loop %loop: symbolic max backedge-taken count is (-1 + (-1 * %a) + %n)
# | 19: Loop %loop: Trip multiple is 1
# | 20: Printing analysis 'Scalar Evolution Analysis' for function 'scaled_nuw_bypass_first':
# | next:10'3 } search range end (exclusive)
# | 21: Classifying expressions for: @scaled_nuw_bypass_first
# | 22: %iv = phi i32 [ %a, %ph ], [ %iv.next, %loop ]
# | 23: --> {%a,+,1}<nuw><%loop> U: full-set S: full-set Exits: (-1 + %n) LoopDispositions: { %loop: Computable }
# | 24: %index = mul nuw i32 %iv, %b
# | next:52'0 { search range start (exclusive)
# | next:52'1 error: no match found in search range
# | 25: --> {(%a * %b)<u nuw>,+,%b}<nuw><%loop> U: full-set S: full-set Exits: ((-1 + %n) * %b) LoopDispositions: { %loop: Computable }
# | next:52'2 ? possible intended match
# | 26: %wide = zext i32 %index to i64
# | 27: --> {(zext i32 (%a * %b)<u nuw> to i64),+,(zext i32 %b to i64)}<nuw><%loop> U: [0,-4294967295) S: [0,-4294967295) Exits: ((zext i32 (%a * %b)<u nuw> to i64) + ((zext i32 (-1 + (-1 * %a) + %n) to i64) * (zext i32 %b to i64))<u nuw>)<u nuw> LoopDispositions: { %loop: Computable }
# | 28: %p = getelementptr i8, ptr %dst, i64 %wide
# | 29: --> {((zext i32 (%a * %b)<u nuw> to i64) + %dst),+,(zext i32 %b to i64)}<nw><%loop> U: full-set S: full-set Exits: ((zext i32 (%a * %b)<u nuw> to i64) + ((zext i32 (-1 + (-1 * %a) + %n) to i64) * (zext i32 %b to i64)) + %dst) LoopDispositions: { %loop: Computable }
# | 30: %iv.next = add nuw i32 %iv, 1
# | 31: --> {(1 + %a),+,1}<nuw><%loop> U: full-set S: full-set Exits: %n LoopDispositions: { %loop: Computable }
# | 32: %bare = mul i32 %a, %b
# | 33: --> (%a * %b) U: full-set S: full-set
# | 34: Determining loop execution counts for: @scaled_nuw_bypass_first
# | 35: Loop %loop: backedge-taken count is (-1 + (-1 * %a) + %n)
# | 36: Loop %loop: constant max backedge-taken count is i32 -1
# | 37: Loop %loop: symbolic max backedge-taken count is (-1 + (-1 * %a) + %n)
# | 38: Loop %loop: Trip multiple is 1
# | 39: Printing analysis 'Scalar Evolution Analysis' for function 'scaled_nuw_exit_count':
# | next:52'3 } search range end (exclusive)
# | 40: Classifying expressions for: @scaled_nuw_exit_count
# | 41: %iv = phi i32 [ %a, %entry ], [ %iv.next, %loop ]
# | 42: --> {%a,+,1}<nuw><%loop> U: full-set S: full-set Exits: ((((-3 * %a) + (-1 * (1 umin ((-3 * %a) + ((3 * %a) umax %n))))<nuw><nsw> + ((3 * %a) umax %n)) /u 3) + (1 umin ((-3 * %a) + ((3 * %a) umax %n))) + %a) LoopDispositions: { %loop: Computable }
# | 43: %index = mul nuw i32 %iv, 3
# | next:95'0 { search range start (exclusive)
# | next:95'1 error: no match found in search range
# | 44: --> {(3 * %a)<u nuw>,+,3}<nuw><%loop> U: full-set S: full-set Exits: ((3 * ((((-3 * %a) + (-1 * (1 umin ((-3 * %a) + ((3 * %a) umax %n))))<nuw><nsw> + ((3 * %a) umax %n)) /u 3) + (1 umin ((-3 * %a) + ((3 * %a) umax %n)))))<u nuw> + (3 * %a))<u nuw> LoopDispositions: { %loop: Computable }
# | next:95'2 ? possible intended match
# | 45: %wide = zext i32 %index to i64
# | 46: --> {(zext i32 (3 * %a)<u nuw> to i64),+,3}<nuw><%loop> U: [0,8589934591) S: [0,8589934591) Exits: ((zext i32 (3 * %a)<u nuw> to i64) + (3 * (zext i32 ((((-3 * %a) + (-1 * (1 umin ((-3 * %a) + ((3 * %a) umax %n))))<nuw><nsw> + ((3 * %a) umax %n)) /u 3) + (1 umin ((-3 * %a) + ((3 * %a) umax %n)))) to i64))<nuw><nsw>)<u nuw> LoopDispositions: { %loop: Computable }
# | 47: %p = getelementptr i8, ptr %dst, i64 %wide
# | 48: --> {((zext i32 (3 * %a)<u nuw> to i64) + %dst),+,3}<nw><%loop> U: full-set S: full-set Exits: ((zext i32 (3 * %a)<u nuw> to i64) + (3 * (zext i32 ((((-3 * %a) + (-1 * (1 umin ((-3 * %a) + ((3 * %a) umax %n))))<nuw><nsw> + ((3 * %a) umax %n)) /u 3) + (1 umin ((-3 * %a) + ((3 * %a) umax %n)))) to i64))<nuw><nsw> + %dst) LoopDispositions: { %loop: Computable }
# | 49: %iv.next = add nuw i32 %iv, 1
# | 50: --> {(1 + %a),+,1}<nw><%loop> U: full-set S: full-set Exits: (1 + (((-3 * %a) + (-1 * (1 umin ((-3 * %a) + ((3 * %a) umax %n))))<nuw><nsw> + ((3 * %a) umax %n)) /u 3) + (1 umin ((-3 * %a) + ((3 * %a) umax %n))) + %a) LoopDispositions: { %loop: Computab
# | ...
# `---data was truncated (10240/13805) (change limit with -D output_limit=N)
# error: command failed with exit status: 1
--
```
</details>
<details>
<summary>LLVM.Transforms/LoopStrengthReduce/X86/scaled-start-use-flags.ll</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\opt.exe -passes=loop-reduce -verify-scev -S C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\opt.exe' -passes=loop-reduce -verify-scev -S 'C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll'
# 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\X86\scaled-start-use-flags.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll:14:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[TMP1:%.*]] = mul i32 [[B]], [[A]]
# | ^
# | <stdin>:11:21: note: scanning from here
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:11:21: note: with "B" equal to "%b"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:11:21: note: with "A" equal to "%a"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:11:21: note: pattern attempts to capture variables: "TMP1"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:34:2: note: possible intended match here
# | %bare = mul i32 %a, %b
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll:69:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[TMP1:%.*]] = mul i32 [[B]], [[A]]
# | ^
# | <stdin>:47:21: note: scanning from here
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:47:21: note: with "B" equal to "%b"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:47:21: note: with "A" equal to "%a"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:47:21: note: pattern attempts to capture variables: "TMP1"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:56:4: note: possible intended match here
# | %lsr.iv = phi i32 [ %lsr.iv.next, %loop ], [ %0, %ph ]
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll:166:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[TMP1:%.*]] = mul i32 [[B]], [[A]]
# | ^
# | <stdin>:101:21: note: scanning from here
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:101:21: note: with "B" equal to "%b"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:101:21: note: with "A" equal to "%a"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:101:21: note: pattern attempts to capture variables: "TMP1"
# | %0 = sub i32 %n, %a
# | ^
# | <stdin>:110:4: note: possible intended match here
# | %lsr.iv = phi i32 [ %lsr.iv.next, %loop ], [ %0, %ph ]
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll:213:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[TMP1:%.*]] = mul i32 [[B]], [[A]]
# | ^
# | <stdin>:126:21: note: scanning from here
# | %0 = sub i32 %a, %n
# | ^
# | <stdin>:126:21: note: with "B" equal to "%b"
# | %0 = sub i32 %a, %n
# | ^
# | <stdin>:126:21: note: with "A" equal to "%a"
# | %0 = sub i32 %a, %n
# | ^
# | <stdin>:126:21: note: pattern attempts to capture variables: "TMP1"
# | %0 = sub i32 %a, %n
# | ^
# | <stdin>:136:4: note: possible intended match here
# | %lsr.iv = phi i32 [ %lsr.iv.next, %loop ], [ %0, %entry ]
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll:294:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[TMP0:%.*]] = mul i32 [[B]], [[A]]
# | ^
# | <stdin>:172:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:172:7: note: with "B" equal to "%b"
# | entry:
# | ^
# | <stdin>:172:7: note: with "A" equal to "%a"
# | entry:
# | ^
# | <stdin>:172:7: note: pattern attempts to capture variables: "TMP0"
# | entry:
# | ^
# | <stdin>:178:2: note: possible intended match here
# | %4 = mul i32 %3, %a
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopStrengthReduce\X86\scaled-start-use-flags.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | .
# | .
# | .
# | 6: define i32 @scaled_nuw(ptr %dst, i32 %a, i32 %b, i32 %n, i1 %enter) {
# | 7: entry:
# | 8: br i1 %enter, label %ph, label %exit
# | 9:
# | 10: ph: ; preds = %entry
# | 11: %0 = sub i32 %n, %a
# | next:14'0 { search range start (exclusive)
# | next:14'1 error: no match found in search range
# | next:14'2 with "B" equal to "%b"
# | next:14'3 with "A" equal to "%a"
# | next:14'4 pattern attempts to capture variables: "TMP1"
# | 12: %1 = mul nuw i32 %b, %a
# | 13: %2 = zext i32 %1 to i64
# | 14: %scevgep = getelementptr i8, ptr %dst, i64 %2
# | 15: %3 = zext i32 %b to i64
# | 16: br label %loop
# | .
# | .
# | .
# | 29:
# | 30: exit: ; preds = %exit.loopexit, %entry
# | 31: ret i32 0
# | 32:
# | 33: bypass: ; No predecessors!
# | 34: %bare = mul i32 %a, %b
# | next:14'5 ? possible intended match
# | 35: ret i32 %bare
# | 36: }
# | 37:
# | 38: define i32 @scaled_nuw_bypass_first(ptr %dst, i32 %a, i32 %b, i32 %n, i1 %enter) {
# | next:14'6 } search range end (exclusive)
# | 39: entry:
# | 40: br i1 %enter, label %ph, label %bypass
# | 41:
# | 42: bypass: ; preds = %entry
# | 43: %bare = mul i32 %a, %b
# | 44: ret i32 %bare
# | 45:
# | 46: ph: ; preds = %entry
# | 47: %0 = sub i32 %n, %a
# | next:69'0 { search range start (exclusive)
# | next:69'1 error: no match found in search range
# | next:69'2 with "B" equal to "%b"
# | next:69'3 with "A" equal to "%a"
# | next:69'4 pattern attempts to capture variables: "TMP1"
# | 48: %1 = mul nuw i32 %b, %a
# | 49: %2 = zext i32 %1 to i64
# | 50: %scevgep = getelementptr i8, ptr %dst, i64 %2
# | 51: %3 = zext i32 %b to i64
# | 52: br label %loop
# | 53:
# | 54: loop: ; preds = %loop, %ph
# | 55: %lsr.iv1 = phi ptr [ %scevgep2, %loop ], [ %scevgep, %ph ]
# | 56: %lsr.iv = phi i32 [ %lsr.iv.next, %loop ], [ %0, %ph ]
# | next:69'5 ? possible intended match
# | 57: store i8 0, ptr %lsr.iv1, align 1
# | 58: %lsr.iv.next = add i32 %lsr.iv, -1
# | 59: %scevgep2 = getelementptr i8, ptr %lsr.iv1, i64 %3
# | 60: %ec = icmp eq i32 %lsr.iv.next, 0
# | 61: br i1 %ec, label %exit, label %loop
# | 62:
# | 63: exit: ; preds = %loop
# | 64: ret i32 0
# | 65: }
# | 66:
# | 67: define i32 @scaled_wrapping(ptr %dst, i32 %a, i32 %b, i32 %n, i1 %enter) {
# | next:69'6 } search range end (exclusive)
# | 68: entry:
# | 69: br i1 %enter, label %ph, label %bypass
# | 70:
# | 71: ph: ; preds = %entry
# | 72: %0 = sub i32 %n, %a
# | .
# | .
# | .
# | 96: entry:
# | 97: %bare = mul i32 %a, %b
# | 98: br i1 %enter, label %ph, label %bypass
# | 99:
# | 100: ph: ; preds = %entry
# | 101: %0 = sub i32 %n, %a
# | next:166'0 { search range start (exclusive)
# | next:166'1 error: no match found in search range
# | next:166'2 with "B" equal to "%b"
# | next:166'3 with "A" equal to "%a"
# | next:166'4 pattern attempts to capture variables: "TMP1"
# | 102: %1 = mul nuw i32 %b, %a
# | 103: %2 = zext i32 %1 to i64
# | 104: %scevgep = getelementptr i8, ptr %dst, i64 %2
# | 105: %3 = zext i32 %b to i64
# | 106: br label %loop
# | 107:
# | 108: loop: ; preds = %loop, %ph
# | 109: %lsr.iv1 = phi ptr [ %scevgep2, %loop ], [ %scevgep, %ph ]
# | 110: %lsr.iv = phi i32 [ %lsr.iv.next, %loop ], [ %0, %ph ]
# | next:166'5 ? possible intended match
# | 111: store i8 0, ptr %lsr.iv1, align 1
# | 112: %lsr.iv.next = add i32 %lsr.iv, -1
# | 113: %scevgep2 = getelementptr i8, ptr %lsr.iv1, i64 %3
# | 114: %ec = icmp eq i32 %lsr.iv.next, 0
# | 115: br i1 %ec, label %exit, label %loop
# | 116:
# | 117: exit: ; preds = %loop
# | 118: ret i32 0
# | 119:
# | 120: bypass: ; preds = %entry
# | 121: ret i32 %bare
# | 122: }
# | 123:
# | 124: define void @scaled_nuw_variable_step(ptr %dst, i32 %a, i32 %b, i32 %step, i32 %n) {
# | next:166'6 } search range end (exclusive)
# | 125: entry:
# | 126: %0 = sub i32 %a, %n
# | next:213'0 { search range start (exclusive)
# | next:213'1 error: no match found in search range
# | next:213'2 with "B" equal to "%b"
# | next:213'3 with "A" equal to "%a"
# | next:213'4 pattern attempts to capture variables: "TMP1"
# | 127: %1 = mul nuw i32 %b, %a
# | 128: %2 = zext i32 %1 to i64
# | 129: %scevgep = getelementptr i8, ptr %dst, i64 %2
# | 130: %3 = mul i32 %step, %b
# | 131: %4 = zext i32 %3 to i64
# | 132: br label %loop
# | 133:
# | 134: loop: ; preds = %loop, %entry
# | 135: %lsr.iv1 = phi ptr [ %scevgep2, %loop ], [ %scevgep, %entry ]
# | 136: %lsr.iv = phi i32 [ %lsr.iv.next, %loop ], [ %0, %entry ]
# | next:213'5 ? possible intended match
# | 137: store i8 0, ptr %lsr.iv1, align 1
# | 138: %lsr.iv.next = add i32 %lsr.iv, %step
# | 139: %scevgep2 = getelementptr i8, ptr %lsr.iv1, i64 %4
# | 140: %ec = icmp eq i32 %lsr.iv.next, 0
# | 141: br i1 %ec, label %exit, label %loop
# | 142:
# | 143: exit: ; preds = %loop
# | 144: ret void
# | 145: }
# | 146:
# | 147: defin
# | ...
# `---data was truncated (10240/12082) (change limit with -D output_limit=N)
# 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/227458
More information about the llvm-commits
mailing list