Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
| Time | Test | |
|---|---|---|
| 60,040 ms | x64 debian > MLIR.Examples/standalone::test.toy |
Event Timeline
| llvm/test/Analysis/ValueTracking/phi-known-nonzero.ll | ||
|---|---|---|
| 212 |
What do you mean 'equal successor case'?
eq_non_zero2 and all the *lt/*le cases? | |
| llvm/test/Analysis/ValueTracking/phi-known-nonzero.ll | ||
|---|---|---|
| 25 | Does just br label %T not work here? I don't think the conditional is needed. | |
| 212 |
br i1 %cmp, label %T, label %T
Oh, I see. You always use br i1 %cmp, label %T, label %F, but in some cases the phi is in %T and in some in %F. Okay, that also works. | |
LGTM, but I think this is still missing a test case for equal successors, something like this:
define i1 @equal_successors(i8 %x) {
entry:
%cmp = icmp ugt i8 %x, 32
br i1 %cmp, label %T, label %T
T:
%v = phi i8 [ %x, %entry], [-1, %F]
%r = icmp eq i8 %v, 0
ret i1 %r
}
Does just br label %T not work here? I don't think the conditional is needed.