[llvm-branch-commits] [llvm] [LV] Vectorize down-counting floating-point argmin/argmax reductions (PR #209827)
via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Fri Oct 9 13:57:10 PDT 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Windows-->
# :window: Windows x64 Test Results
* 143827 tests passed
* 3508 tests skipped
* 1 test failed
## Failed Tests
(click on a test name to see its output)
### LLVM
<details>
<summary>LLVM.Transforms/LoopVectorize/select-last-index-fp.ll</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 2
c:\_work\llvm-project\llvm-project\build\bin\opt.exe -passes=loop-vectorize -force-vector-width=4 -force-vector-interleave=1 -S C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll | c:\_work\llvm-project\llvm-project\build\bin\filecheck.exe C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll
# executed command: 'c:\_work\llvm-project\llvm-project\build\bin\opt.exe' -passes=loop-vectorize -force-vector-width=4 -force-vector-interleave=1 -S 'C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.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\LoopVectorize\select-last-index-fp.ll'
# .---command stderr------------
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll:9:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[MIN_ITERS_CHECK:%.*]] = icmp ult i64 [[N]], 4
# | ^
# | <stdin>:5:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:5:7: note: with "N" equal to "%n"
# | entry:
# | ^
# | <stdin>:5:7: note: pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | entry:
# | ^
# | <stdin>:18:9: note: possible intended match here
# | %exitcond.not = icmp eq i64 %iv.next, %n
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll:87:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[MIN_ITERS_CHECK:%.*]] = icmp ult i64 [[N]], 4
# | ^
# | <stdin>:27:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:27:7: note: with "N" equal to "%n"
# | entry:
# | ^
# | <stdin>:27:7: note: pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | entry:
# | ^
# | <stdin>:40:9: note: possible intended match here
# | %exitcond.not = icmp eq i64 %iv.next, %n
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll:209:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[MIN_ITERS_CHECK:%.*]] = icmp ult i64 [[N]], 4
# | ^
# | <stdin>:71:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:71:7: note: with "N" equal to "%n"
# | entry:
# | ^
# | <stdin>:71:7: note: pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | entry:
# | ^
# | <stdin>:84:9: note: possible intended match here
# | %exitcond.not = icmp eq i64 %iv.next, %n
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll:287:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[MIN_ITERS_CHECK:%.*]] = icmp ult i64 [[N]], 4
# | ^
# | <stdin>:93:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:93:7: note: with "N" equal to "%n"
# | entry:
# | ^
# | <stdin>:93:7: note: pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | entry:
# | ^
# | <stdin>:106:9: note: possible intended match here
# | %exitcond.not = icmp eq i64 %iv.next, %n
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll:758:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[MIN_ITERS_CHECK:%.*]] = icmp ult i64 [[N]], 4
# | ^
# | <stdin>:313:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:313:7: note: with "N" equal to "%n"
# | entry:
# | ^
# | <stdin>:313:7: note: pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | entry:
# | ^
# | <stdin>:326:9: note: possible intended match here
# | %exitcond.not = icmp eq i64 %iv.next, %n
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll:968:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[MIN_ITERS_CHECK:%.*]] = icmp ult i64 [[N]], 4
# | ^
# | <stdin>:401:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:401:7: note: with "N" equal to "%n"
# | entry:
# | ^
# | <stdin>:401:7: note: pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | entry:
# | ^
# | <stdin>:414:9: note: possible intended match here
# | %exitcond.not = icmp eq i64 %iv.next, %n
# | ^
# | C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll:1092:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: [[MIN_ITERS_CHECK:%.*]] = icmp ult i64 [[N]], 4
# | ^
# | <stdin>:445:7: note: scanning from here
# | entry:
# | ^
# | <stdin>:445:7: note: with "N" equal to "%n"
# | entry:
# | ^
# | <stdin>:445:7: note: pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | entry:
# | ^
# | <stdin>:458:9: note: possible intended match here
# | %exitcond.not = icmp eq i64 %iv.next, %n
# | ^
# |
# | Input file: <stdin>
# | Check file: C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | 1: ; ModuleID = 'C:\_work\llvm-project\llvm-project\llvm\test\Transforms\LoopVectorize\select-last-index-fp.ll'
# | 2: source_filename = "C:\\_work\\llvm-project\\llvm-project\\llvm\\test\\Transforms\\LoopVectorize\\select-last-index-fp.ll"
# | 3:
# | 4: define i64 @test_fmax_last_idx(ptr %src, i64 %n) {
# | 5: entry:
# | next:9'0 { search range start (exclusive)
# | next:9'1 error: no match found in search range
# | next:9'2 with "N" equal to "%n"
# | next:9'3 pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | 6: br label %loop
# | 7:
# | 8: loop: ; preds = %loop, %entry
# | 9: %iv = phi i64 [ 0, %entry ], [ %iv.next, %loop ]
# | 10: %max.idx = phi i64 [ 0, %entry ], [ %max.idx.next, %loop ]
# | 11: %max.val = phi float [ f0xFF7FFFFF, %entry ], [ %max.val.next, %loop ]
# | 12: %gep = getelementptr float, ptr %src, i64 %iv
# | 13: %l = load float, ptr %gep, align 4
# | 14: %cmp = fcmp nnan nsz ole float %max.val, %l
# | 15: %max.val.next = call nnan nsz float @llvm.maxnum.f32(float %l, float %max.val)
# | 16: %max.idx.next = select i1 %cmp, i64 %iv, i64 %max.idx
# | 17: %iv.next = add nuw nsw i64 %iv, 1
# | 18: %exitcond.not = icmp eq i64 %iv.next, %n
# | next:9'4 ? possible intended match
# | 19: br i1 %exitcond.not, label %exit, label %loop
# | 20:
# | 21: exit: ; preds = %loop
# | 22: %res = phi i64 [ %max.idx.next, %loop ]
# | 23: ret i64 %res
# | 24: }
# | 25:
# | 26: define i64 @test_fmax_last_idx_cond_flipped(ptr %src, i64 %n) {
# | next:9'5 } search range end (exclusive)
# | 27: entry:
# | next:87'0 { search range start (exclusive)
# | next:87'1 error: no match found in search range
# | next:87'2 with "N" equal to "%n"
# | next:87'3 pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | 28: br label %loop
# | 29:
# | 30: loop: ; preds = %loop, %entry
# | 31: %iv = phi i64 [ 0, %entry ], [ %iv.next, %loop ]
# | 32: %max.idx = phi i64 [ 0, %entry ], [ %max.idx.next, %loop ]
# | 33: %max.val = phi float [ f0xFF7FFFFF, %entry ], [ %max.val.next, %loop ]
# | 34: %gep = getelementptr float, ptr %src, i64 %iv
# | 35: %l = load float, ptr %gep, align 4
# | 36: %cmp = fcmp nnan nsz oge float %l, %max.val
# | 37: %max.val.next = call nnan nsz float @llvm.maxnum.f32(float %l, float %max.val)
# | 38: %max.idx.next = select i1 %cmp, i64 %iv, i64 %max.idx
# | 39: %iv.next = add nuw nsw i64 %iv, 1
# | 40: %exitcond.not = icmp eq i64 %iv.next, %n
# | next:87'4 ? possible intended match
# | 41: br i1 %exitcond.not, label %exit, label %loop
# | 42:
# | 43: exit: ; preds = %loop
# | 44: %res = phi i64 [ %max.idx.next, %loop ]
# | 45: ret i64 %res
# | 46: }
# | 47:
# | 48: define i64 @test_fmax_last_idx_strict(ptr %src, i64 %n) {
# | next:87'5 } search range end (exclusive)
# | 49: entry:
# | 50: br label %loop
# | 51:
# | 52: loop: ; preds = %loop, %entry
# | 53: %iv = phi i64 [ 0, %entry ], [ %iv.next, %loop ]
# | .
# | .
# | .
# | 66: %res = phi i64 [ %max.idx.next, %loop ]
# | 67: ret i64 %res
# | 68: }
# | 69:
# | 70: define i64 @test_fmin_last_idx(ptr %src, i64 %n) {
# | 71: entry:
# | next:209'0 { search range start (exclusive)
# | next:209'1 error: no match found in search range
# | next:209'2 with "N" equal to "%n"
# | next:209'3 pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | 72: br label %loop
# | 73:
# | 74: loop: ; preds = %loop, %entry
# | 75: %iv = phi i64 [ 0, %entry ], [ %iv.next, %loop ]
# | 76: %min.idx = phi i64 [ 0, %entry ], [ %min.idx.next, %loop ]
# | 77: %min.val = phi float [ f0x7F7FFFFF, %entry ], [ %min.val.next, %loop ]
# | 78: %gep = getelementptr float, ptr %src, i64 %iv
# | 79: %l = load float, ptr %gep, align 4
# | 80: %cmp = fcmp nnan nsz oge float %min.val, %l
# | 81: %min.val.next = call nnan nsz float @llvm.minnum.f32(float %l, float %min.val)
# | 82: %min.idx.next = select i1 %cmp, i64 %iv, i64 %min.idx
# | 83: %iv.next = add nuw nsw i64 %iv, 1
# | 84: %exitcond.not = icmp eq i64 %iv.next, %n
# | next:209'4 ? possible intended match
# | 85: br i1 %exitcond.not, label %exit, label %loop
# | 86:
# | 87: exit: ; preds = %loop
# | 88: %res = phi i64 [ %min.idx.next, %loop ]
# | 89: ret i64 %res
# | 90: }
# | 91:
# | 92: define i64 @test_fmin_last_idx_cond_flipped(ptr %src, i64 %n) {
# | next:209'5 } search range end (exclusive)
# | 93: entry:
# | next:287'0 { search range start (exclusive)
# | next:287'1 error: no match found in search range
# | next:287'2 with "N" equal to "%n"
# | next:287'3 pattern attempts to capture variables: "MIN_ITERS_CHECK"
# | 94: br label %loop
# | 95:
# | 96: loop: ; preds = %loop, %entry
# | 97: %iv = phi i64 [ 0, %entry ], [ %iv.next, %loop ]
# | 98: %min.idx = phi i64 [ 0, %entry ], [ %min.idx.next, %loop ]
# | 99: %min.val = phi float [ f0x7F7FFFFF, %entry ], [ %min.val.next, %loop ]
# | 100: %gep = getelementptr float, ptr %src, i64 %iv
# | 101: %l = load float, ptr %gep, align 4
# | 102
# | ...
# `---data was truncated (10240/17387) (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/209827
More information about the llvm-branch-commits
mailing list