forked from OSchip/llvm-project
[CGP] Fix the bug found by asan.
Try to fix the asan failure introduced by r317429. llvm-svn: 317431
This commit is contained in:
parent
cde03f3d27
commit
aee6375b02
|
@ -4278,8 +4278,8 @@ bool CodeGenPrepare::optimizeMemoryInst(Instruction *MemoryInst, Value *Addr,
|
|||
// the graph are compatible.
|
||||
bool PhiOrSelectSeen = false;
|
||||
SmallVector<Instruction*, 16> AddrModeInsts;
|
||||
AddressingModeCombiner AddrModes({ *DL, TLInfo },
|
||||
{ Addr, MemoryInst->getParent() });
|
||||
const SimplifyQuery SQ(*DL, TLInfo);
|
||||
AddressingModeCombiner AddrModes(SQ, { Addr, MemoryInst->getParent() });
|
||||
TypePromotionTransaction TPT(RemovedInsts);
|
||||
TypePromotionTransaction::ConstRestorationPt LastKnownGood =
|
||||
TPT.getRestorationPoint();
|
||||
|
|
Loading…
Reference in New Issue