mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-06 20:32:19 +00:00
Fix Regression/Transforms/LoopStrengthReduce/dont_insert_redundant_ops.ll,
hopefully not breaking too many other things. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20505 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
2d9005d61f
commit
3f93197098
@ -189,7 +189,7 @@ void LoopStrengthReduce::strengthReduceGEP(GetElementPtrInst *GEPI, Loop *L,
|
|||||||
// that it was the induction variable, and has been replaced by a constant
|
// that it was the induction variable, and has been replaced by a constant
|
||||||
// null value. In this case, replace the GEP with a use of pointer directly.
|
// null value. In this case, replace the GEP with a use of pointer directly.
|
||||||
PHINode *NewPHI;
|
PHINode *NewPHI;
|
||||||
if (1) {
|
if (Cache->CachedPHINode == 0) {
|
||||||
Value *PreGEP;
|
Value *PreGEP;
|
||||||
if (AllConstantOperands && isa<Constant>(GEPI->getOperand(0))) {
|
if (AllConstantOperands && isa<Constant>(GEPI->getOperand(0))) {
|
||||||
Constant *C = dyn_cast<Constant>(GEPI->getOperand(0));
|
Constant *C = dyn_cast<Constant>(GEPI->getOperand(0));
|
||||||
|
Loading…
Reference in New Issue
Block a user