|
|
| Bugzilla Link |
9004 |
| Resolution |
FIXED |
| Resolved on |
Nov 21, 2017 04:25 |
| Version |
trunk |
| OS |
Linux |
| Reporter |
LLVM Bugzilla Contributor |
| CC |
@fhahn,@nunoplopes |
Extended Description
Run "opt -gvn" on the following testcase. It gets that "ret i1 %cond2" returns
false, but it doesn't see that the a priori easier "ret i1 %cond" returns true!
define i1 @foo(i32 %x) {
%cond = icmp eq i32 %x, 0
br i1 %cond, label %iftrue, label %iffalse
iftrue:
ret i1 %cond
iffalse:
%cond2 = icmp eq i32 %x, 0
ret i1 %cond2
}