[llvm] [SimpleLoopUnswitch] Fix bug in partially invariant unswitching (PR #222118)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 8 14:48:22 PDT 2026
github-actions[bot] wrote:
<!--PREMERGE ADVISOR COMMENT: Linux-->
# :penguin: Linux x64 Test Results
* 152795 tests passed
* 3273 tests skipped
* 1 test failed
## Failed Tests
(click on a test name to see its output)
### LLVM
<details>
<summary>LLVM.Transforms/SimpleLoopUnswitch/pr219510.ll</summary>
```
Exit Code: 1
Command Output (stdout):
--
# RUN: at line 1
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/opt -passes='loop-mssa(simple-loop-unswitch<nontrivial>)' -S < /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/Transforms/SimpleLoopUnswitch/pr219510.ll | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/Transforms/SimpleLoopUnswitch/pr219510.ll
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/opt '-passes=loop-mssa(simple-loop-unswitch<nontrivial>)' -S
# note: command had no output on stdout or stderr
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/Transforms/SimpleLoopUnswitch/pr219510.ll
# .---command stderr------------
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/Transforms/SimpleLoopUnswitch/pr219510.ll:7:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: %lv = load i32, ptr %ptr
# | ^
# | <stdin>:40:2: note: 'next' match was here
# | %lv = load i32, ptr %ptr, align 4
# | ^
# | <stdin>:20:22: note: previous match ended here
# | call void @barrier()
# | ^
# | <stdin>:21:1: note: non-matching line after previous match is here
# | br label %noclobber.us
# | ^
# |
# | Input file: <stdin>
# | Check file: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/Transforms/SimpleLoopUnswitch/pr219510.ll
# |
# | -dump-input=help explains the following input dump.
# |
# | Input was:
# | <<<<<<
# | .
# | .
# | .
# | 15: entry.split.us: ; preds = %entry
# | 16: br label %loop.header.us
# | 17:
# | 18: loop.header.us: ; preds = %loop.latch.us, %entry.split.us
# | 19: %iv.us = phi i32 [ 0, %entry.split.us ], [ %iv.next.us, %loop.latch.us ]
# | 20: call void @barrier()
# | next:7'0 { search range start (exclusive)
# | 21: br label %noclobber.us
# | 22:
# | 23: noclobber.us: ; preds = %loop.header.us
# | 24: br label %loop.latch.us
# | 25:
# | .
# | .
# | .
# | 35: br label %loop.header
# | 36:
# | 37: loop.header: ; preds = %loop.latch, %entry.split
# | 38: %iv = phi i32 [ 0, %entry.split ], [ %iv.next, %loop.latch ]
# | 39: call void @barrier()
# | 40: %lv = load i32, ptr %ptr, align 4
# | next:7'1 !~~~~~~~~~~~~~~~~~~~~~~~ error: match on wrong line
# | 41: %sc = icmp eq i32 %lv, 100
# | 42: br i1 %sc, label %noclobber, label %clobber
# | 43:
# | 44: noclobber: ; preds = %loop.header
# | 45: br label %loop.latch
# | .
# | .
# | .
# | 61: }
# | 62:
# | 63: attributes #0 = { memory(read) }
# | 64:
# | 65: !0 = distinct !{!0, !1}
# | 66: !1 = !{!"llvm.loop.unswitch.partial.disable"}
# | next:7'2 } search range end (exclusive)
# | >>>>>>
# `-----------------------------
# 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/222118
More information about the llvm-commits
mailing list