llvm-project
llvm-project copied to clipboard
InstCombine assertion at vector gep/icmp folding
| Bugzilla Link | 38984 |
| Resolution | FIXED |
| Resolved on | Sep 25, 2018 00:25 |
| Version | trunk |
| OS | Linux |
| Attachments | reduced reproducer |
| CC | @davidbolvansky,@RKSimon,@rotateright |
Extended Description
The attached IR fails with:
opt: ../lib/IR/Value.cpp:413: void llvm::Value::doRAUW(llvm::Value *, llvm::Value::ReplaceMetadataUses): Assertion `New->getType() == getType() && "replaceAllUses of value with new value of different type!"' failed.
when invoking:
opt -instcombine -S addr_diff_reduced.ll
The reason is that InstCombiner::foldGEPICmp() sees a vector icmp that it knows to be all true and tries to replace it with an i1 true value.
mentioned in issue llvm/llvm-bugzilla-archive#51824
Fixed by rL342647.
@Jesper Resolve this now that D52263/rL342647 has landed?