File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed
llvm/lib/Transforms/InstCombine Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -1975,8 +1975,6 @@ Instruction *InstCombiner::visitGetElementPtrInst(GetElementPtrInst &GEP) {
19751975 if (DI == -1 ) {
19761976 // All the GEPs feeding the PHI are identical. Clone one down into our
19771977 // BB so that it can be merged with the current GEP.
1978- GEP.getParent ()->getInstList ().insert (
1979- GEP.getParent ()->getFirstInsertionPt (), NewGEP);
19801978 } else {
19811979 // All the GEPs feeding the PHI differ at a single offset. Clone a GEP
19821980 // into the current block so it can be merged, and create a new PHI to
@@ -1994,11 +1992,10 @@ Instruction *InstCombiner::visitGetElementPtrInst(GetElementPtrInst &GEP) {
19941992 PN->getIncomingBlock (I));
19951993
19961994 NewGEP->setOperand (DI, NewPN);
1997- GEP.getParent ()->getInstList ().insert (
1998- GEP.getParent ()->getFirstInsertionPt (), NewGEP);
1999- NewGEP->setOperand (DI, NewPN);
20001995 }
20011996
1997+ GEP.getParent ()->getInstList ().insert (
1998+ GEP.getParent ()->getFirstInsertionPt (), NewGEP);
20021999 GEP.setOperand (0 , NewGEP);
20032000 PtrOp = NewGEP;
20042001 }
You can’t perform that action at this time.
0 commit comments