Home
last modified time | relevance | path

Searched refs:MSSA (Results 1 – 25 of 38) sorted by relevance

12

/freebsd/contrib/llvm-project/llvm/lib/Analysis/
H A DMemorySSAUpdater.cpp46 if (!MSSA->DT->isReachableFromEntry(BB)) in getPreviousDefRecursive()
47 return MSSA->getLiveOnEntryDef(); in getPreviousDefRecursive()
61 MemoryAccess *Result = MSSA->createMemoryPhi(BB); in getPreviousDefRecursive()
76 if (MSSA->DT->isReachableFromEntry(Pred)) { in getPreviousDefRecursive()
84 PhiOps.push_back(MSSA->getLiveOnEntryDef()); in getPreviousDefRecursive()
89 MemoryPhi *Phi = dyn_cast_or_null<MemoryPhi>(MSSA->getMemoryAccess(BB)); in getPreviousDefRecursive()
104 Phi = MSSA->createMemoryPhi(BB); in getPreviousDefRecursive()
148 auto *Defs = MSSA->getWritableBlockDefs(MA->getBlock()); in getPreviousDefInBlock()
160 auto End = MSSA->getWritableBlockAccesses(MA->getBlock())->rend(); in getPreviousDefInBlock()
175 auto *Defs = MSSA->getWritableBlockDefs(BB); in getPreviousDefFromEnd()
[all …]
H A DMemorySSA.cpp98 const MemorySSA *MSSA; member in __anon72856b230111::MemorySSAAnnotatedWriter
101 MemorySSAAnnotatedWriter(const MemorySSA *M) : MSSA(M) {} in MemorySSAAnnotatedWriter()
105 if (MemoryAccess *MA = MSSA->getMemoryAccess(BB)) in emitBasicBlockStartAnnot()
111 if (MemoryAccess *MA = MSSA->getMemoryAccess(I)) in emitInstructionAnnot()
119 MemorySSA *MSSA; member in __anon72856b230111::MemorySSAWalkerAnnotatedWriter
125 : MSSA(M), Walker(M->getWalker()), BAA(M->getAA()) {} in MemorySSAWalkerAnnotatedWriter()
129 if (MemoryAccess *MA = MSSA->getMemoryAccess(BB)) in emitBasicBlockStartAnnot()
135 if (MemoryAccess *MA = MSSA->getMemoryAccess(I)) { in emitInstructionAnnot()
140 if (MSSA->isLiveOnEntryDef(Clobber)) in emitInstructionAnnot()
398 const MemoryLocation &StartLoc, const MemorySSA &MSSA, in checkClobberSanity() argument
[all …]
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Scalar/
H A DLoopInstSimplify.cpp71 MemorySSA *MSSA = MSSAU ? MSSAU->getMemorySSA() : nullptr; in simplifyLoopInst() local
76 MSSA->verifyMemorySSA(); in simplifyLoopInst()
132 if (MemoryAccess *MA = MSSA->getMemoryAccess(&I)) in simplifyLoopInst()
133 if (MemoryAccess *ReplacementMA = MSSA->getMemoryAccess(SimpleI)) in simplifyLoopInst()
152 MSSA->verifyMemorySSA(); in simplifyLoopInst()
174 if (AR.MSSA) { in run()
175 MSSAU = MemorySSAUpdater(AR.MSSA); in run()
177 AR.MSSA->verifyMemorySSA(); in run()
185 if (AR.MSSA) in run()
H A DMemCpyOptimizer.cpp110 static bool overreadUndefContents(MemorySSA *MSSA, MemCpyInst *MemCpy,
322 static bool writtenBetween(MemorySSA *MSSA, BatchAAResults &AA, in writtenBetween() argument
342 MemoryAccess *Clobber = MSSA->getWalker()->getClobberingMemoryAccess( in writtenBetween()
344 return !MSSA->dominates(Clobber, Start); in writtenBetween()
375 cast_or_null<MemoryUseOrDef>(MSSA->getMemoryAccess(&*BI)); in tryMergingIntoMemset()
601 if (MemoryUseOrDef *MA = MSSA->getMemoryAccess(P)) { in moveUp()
607 if (MemoryUseOrDef *MA = MSSA->getMemoryAccess(&I)) { in moveUp()
619 if (MemoryUseOrDef *MA = MSSA->getMemoryAccess(I)) { in moveUp()
687 auto *LastDef = cast<MemoryDef>(MSSA->getMemoryAccess(SI)); in processStoreOfLoad()
708 MSSA->getWalker()->getClobberingMemoryAccess(LI, BAA))) in processStoreOfLoad()
[all …]
H A DLoopRotation.cpp75 if (AR.MSSA) in run()
76 MSSAU = MemorySSAUpdater(AR.MSSA); in run()
84 if (AR.MSSA && VerifyMemorySSA) in run()
85 AR.MSSA->verifyMemorySSA(); in run()
88 if (AR.MSSA) in run()
H A DLoopTermFold.cpp232 TargetLibraryInfo &TLI, MemorySSA *MSSA) { in RunTermFold() argument
234 if (MSSA) in RunTermFold()
235 MSSAU = std::make_unique<MemorySSAUpdater>(MSSA); in RunTermFold()
347 MemorySSA *MSSA = nullptr; in runOnLoop() local
349 MSSA = &MSSAAnalysis->getMSSA(); in runOnLoop()
350 return RunTermFold(L, SE, DT, LI, TTI, TLI, MSSA); in runOnLoop()
356 if (!RunTermFold(&L, AR.SE, AR.DT, AR.LI, AR.TTI, AR.TLI, AR.MSSA)) in run()
360 if (AR.MSSA) in run()
H A DLICM.cpp189 static bool noConflictingReadWrites(Instruction *I, MemorySSA *MSSA,
192 static bool pointerInvalidatedByLoop(MemorySSA *MSSA, MemoryUse *MU,
196 static bool pointerInvalidatedByBlock(BasicBlock &BB, MemorySSA &MSSA,
214 static void foreachMemoryAccess(MemorySSA *MSSA, Loop *L,
219 collectPromotionCandidates(MemorySSA *MSSA, AliasAnalysis *AA, Loop *L);
225 TargetTransformInfo *TTI, ScalarEvolution *SE, MemorySSA *MSSA,
262 MemorySSA *MSSA = &getAnalysis<MemorySSAWrapperPass>().getMSSA(); in runOnLoop() local
274 SE ? &SE->getSE() : nullptr, MSSA, &ORE); in runOnLoop()
301 if (!AR.MSSA) in run()
312 &AR.SE, AR.MSSA, &ORE)) in run()
[all …]
H A DLoopDeletion.cpp400 LoopInfo &LI, MemorySSA *MSSA, in breakBackedgeIfNotTaken() argument
418 breakLoopBackedge(L, DT, SE, LI, MSSA); in breakBackedgeIfNotTaken()
438 MemorySSA *MSSA, in deleteLoopIfDead() argument
477 deleteDeadLoop(L, &DT, &SE, &LI, MSSA); in deleteLoopIfDead()
510 deleteDeadLoop(L, &DT, &SE, &LI, MSSA); in deleteLoopIfDead()
527 auto Result = deleteLoopIfDead(&L, AR.DT, AR.SE, AR.LI, AR.MSSA, ORE); in run()
534 AR.MSSA, ORE)); in run()
543 if (AR.MSSA) in run()
H A DLoopSink.cpp300 MemorySSA &MSSA, in sinkLoopInvariantInstructions() argument
317 MemorySSAUpdater MSSAU(&MSSA); in sinkLoopInvariantInstructions()
318 SinkAndHoistLICMFlags LICMFlags(/*IsSink=*/true, L, MSSA); in sinkLoopInvariantInstructions()
371 MemorySSA &MSSA = FAM.getResult<MemorySSAAnalysis>(F).getMSSA(); in run() local
391 Changed |= sinkLoopInvariantInstructions(L, AA, LI, DT, BFI, MSSA, in run()
403 MSSA.verifyMemorySSA(); in run()
H A DGVNHoist.cpp246 MemoryDependenceResults *MD, MemorySSA *MSSA) in GVNHoist() argument
247 : DT(DT), PDT(PDT), AA(AA), MD(MD), MSSA(MSSA), in GVNHoist()
248 MSSAUpdater(std::make_unique<MemorySSAUpdater>(MSSA)) { in GVNHoist()
249 MSSA->ensureOptimizedUses(); in GVNHoist()
268 MemorySSA *MSSA; member in llvm::GVNHoist
586 const MemorySSA::AccessList *Acc = MSSA->getBlockAccesses(BB); in hasMemoryUse()
722 if (NewBB == DBB && !MSSA->isLiveOnEntryDef(D)) in safeToHoistLdSt()
739 assert(MSSA->locallyDominates(D, U)); in safeToHoistLdSt()
775 if (MemoryUseOrDef *UD = MSSA->getMemoryAccess(Insn)) in checkSafety()
980 MemoryAccess *OldMA = MSSA->getMemoryAccess(I); in rauw()
[all …]
H A DLoopPassManager.cpp221 MemorySSA *MSSA = in run() local
239 MSSA}; in run()
310 if (LAR.MSSA && !PassPA.getChecker<MemorySSAAnalysis>().preserved()) in run()
322 if (LAR.MSSA && VerifyMemorySSA) in run()
323 LAR.MSSA->verifyMemorySSA(); in run()
H A DDeadStoreElimination.cpp951 MemorySSA &MSSA; member
997 DSEState(Function &F, AliasAnalysis &AA, MemorySSA &MSSA, DominatorTree &DT, in DSEState()
1000 : F(F), AA(AA), EA(DT, &LI), BatchAA(AA, &EA), MSSA(MSSA), DT(DT), in DSEState()
1008 MemoryAccess *MA = MSSA.getMemoryAccess(&I); in DSEState()
1505 if (!MSSA.isLiveOnEntryDef(Current) && isa<MemoryUseOrDef>(Current)) in getDomMemoryDef()
1512 if (MSSA.isLiveOnEntryDef(Current)) { in getDomMemoryDef()
1572 return !MSSA.dominates(StartAccess, UseOrDef) && in getDomMemoryDef()
1858 MemorySSAUpdater Updater(&MSSA); in deleteDeadInstruction()
1872 MemoryAccess *MA = MSSA.getMemoryAccess(DeadInst); in deleteDeadInstruction()
2045 auto *MallocDef = dyn_cast_or_null<MemoryDef>(MSSA.getMemoryAccess(Malloc)); in tryFoldIntoCalloc()
[all …]
H A DEarlyCSE.cpp641 MemorySSA *MSSA; member in __anon2439b80b0411::EarlyCSE
728 AssumptionCache &AC, MemorySSA *MSSA) in EarlyCSE() argument
729 : TLI(TLI), TTI(TTI), DT(DT), AC(AC), SQ(DL, &TLI, &DT, &AC), MSSA(MSSA), in EarlyCSE()
730 MSSAUpdater(std::make_unique<MemorySSAUpdater>(MSSA)) {} in EarlyCSE()
1088 if (!MSSA) in removeMSSA()
1091 MSSA->verifyMemorySSA(); in removeMSSA()
1128 if (!MSSA) in isSameMemGeneration()
1138 auto *EarlierMA = MSSA->getMemoryAccess(EarlierInst); in isSameMemGeneration()
1141 auto *LaterMA = MSSA->getMemoryAccess(LaterInst); in isSameMemGeneration()
1151 LaterDef = MSSA->getWalker()->getClobberingMemoryAccess(LaterInst); in isSameMemGeneration()
[all …]
H A DGVN.cpp484 assert(MSSA && "addMemoryStateToExp should not be called without MemorySSA"); in addMemoryStateToExp()
485 assert(MSSA->getMemoryAccess(I) && "Instruction does not access memory"); in addMemoryStateToExp()
486 MemoryAccess *MA = MSSA->getSkipSelfWalker()->getClobberingMemoryAccess(I); in addMemoryStateToExp()
610 if (MSSA && IsMSSAEnabled && AA->onlyReadsMemory(C)) { in lookupOrAddCall()
624 if (!MSSA || !IsMSSAEnabled) { in computeLoadStoreVN()
647 return MSSA->isLiveOnEntryDef(MA) || isa<MemoryPhi>(MA) in lookupOrAdd()
893 auto *MSSA = AM.getCachedResult<MemorySSAAnalysis>(F); in run() local
894 if (isMemorySSAEnabled() && !MSSA) { in run()
897 MSSA = &AM.getResult<MemorySSAAnalysis>(F); in run()
901 MSSA ? &MSSA->getMSSA() : nullptr); in run()
[all …]
/freebsd/contrib/llvm-project/llvm/lib/Target/AMDGPU/
H A DAMDGPUAnnotateUniformValues.cpp33 MemorySSA *MSSA; member in __anon408c60bb0111::AMDGPUAnnotateUniformValues
49 AMDGPUAnnotateUniformValues(UniformityInfo &UA, MemorySSA &MSSA, in AMDGPUAnnotateUniformValues() argument
51 : UA(&UA), MSSA(&MSSA), AA(&AA), in AMDGPUAnnotateUniformValues()
81 if (GlobalLoad && !AMDGPU::isClobberedInFunction(&I, MSSA, AA)) in visitLoadInst()
89 MemorySSA &MSSA = FAM.getResult<MemorySSAAnalysis>(F).getMSSA(); in run() local
92 AMDGPUAnnotateUniformValues Impl(UI, MSSA, AA, F); in run()
131 MemorySSA &MSSA = getAnalysis<MemorySSAWrapperPass>().getMSSA(); in runOnFunction() local
134 AMDGPUAnnotateUniformValues Impl(UI, MSSA, AA, F); in runOnFunction()
H A DAMDGPUPromoteKernelArguments.cpp33 MemorySSA *MSSA; member in __anon4eb9f4ae0111::AMDGPUPromoteKernelArguments
52 bool run(Function &F, MemorySSA &MSSA, AliasAnalysis &AA);
79 !AMDGPU::isClobberedInFunction(LD, MSSA, AA)) in enqueueUsers()
153 bool AMDGPUPromoteKernelArguments::run(Function &F, MemorySSA &MSSA, in run() argument
163 this->MSSA = &MSSA; in run()
189 MemorySSA &MSSA = getAnalysis<MemorySSAWrapperPass>().getMSSA(); in runOnFunction() local
191 return run(F, MSSA, AA); in runOnFunction()
210 MemorySSA &MSSA = AM.getResult<MemorySSAAnalysis>(F).getMSSA(); in run() local
212 if (AMDGPUPromoteKernelArguments().run(F, MSSA, AA)) { in run()
H A DAMDGPUMemoryUtils.cpp380 bool isClobberedInFunction(const LoadInst *Load, MemorySSA *MSSA, in isClobberedInFunction() argument
382 MemorySSAWalker *Walker = MSSA->getWalker(); in isClobberedInFunction()
402 if (MSSA->isLiveOnEntryDef(MA)) in isClobberedInFunction()
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Utils/
H A DMoveAutoInit.cpp62 DominatorTree &DT, MemorySSA &MSSA) { in usersDominator() argument
64 MemoryUseOrDef &IMA = *MSSA.getMemoryAccess(I); in usersDominator()
65 BatchAAResults AA(MSSA.getAA()); in usersDominator()
104 static bool runMoveAutoInit(Function &F, DominatorTree &DT, MemorySSA &MSSA) { in runMoveAutoInit() argument
122 BasicBlock *UsersDominator = usersDominator(ML.value(), &I, DT, MSSA); in runMoveAutoInit()
200 MemorySSAUpdater MSSAU(&MSSA); in runMoveAutoInit()
207 MSSAU.moveToPlace(MSSA.getMemoryAccess(Job.first), Job.first->getParent(), in runMoveAutoInit()
212 MSSA.verifyMemorySSA(); in runMoveAutoInit()
223 auto &MSSA = AM.getResult<MemorySSAAnalysis>(F).getMSSA(); in run() local
224 if (!runMoveAutoInit(F, DT, MSSA)) in run()
H A DLoopUnroll.cpp260 MemorySSA *MSSA = GetMSSA(); in getMatchingValue() local
261 if (!MSSA) in getMatchingValue()
263 auto *EarlierMA = MSSA->getMemoryAccess(LV.DefI); in getMatchingValue()
265 MSSA->getWalker()->getClobberingMemoryAccess(LI, BAA); in getMatchingValue()
266 if (!MSSA->dominates(LaterDef, EarlierMA)) in getMatchingValue()
361 std::unique_ptr<MemorySSA> MSSA = nullptr; in simplifyLoopAfterUnroll() local
363 loadCSE(L, *DT, *SE, *LI, BAA, [L, AA, DT, &MSSA]() -> MemorySSA * { in simplifyLoopAfterUnroll()
364 if (!MSSA) in simplifyLoopAfterUnroll()
365 MSSA.reset(new MemorySSA(*L, AA, DT)); in simplifyLoopAfterUnroll()
366 return &*MSSA; in simplifyLoopAfterUnroll()
H A DLoopUtils.cpp486 LoopInfo *LI, MemorySSA *MSSA) { in deleteDeadLoop() argument
492 if (MSSA) in deleteDeadLoop()
493 MSSAU = std::make_unique<MemorySSAUpdater>(MSSA); in deleteDeadLoop()
572 if (MSSA) { in deleteDeadLoop()
576 MSSA->verifyMemorySSA(); in deleteDeadLoop()
596 if (MSSA) { in deleteDeadLoop()
603 MSSA->verifyMemorySSA(); in deleteDeadLoop()
676 if (MSSA && VerifyMemorySSA) in deleteDeadLoop()
677 MSSA->verifyMemorySSA(); in deleteDeadLoop()
712 LoopInfo &LI, MemorySSA *MSSA) { in breakLoopBackedge() argument
[all …]
/freebsd/contrib/llvm-project/llvm/include/llvm/Analysis/
H A DMemorySSAUpdater.h57 MemorySSA *MSSA;
67 MemorySSAUpdater(MemorySSA *MSSA) : MSSA(MSSA) {} in MemorySSAUpdater() argument
224 if (MemoryAccess *MA = MSSA->getMemoryAccess(I))
243 MemorySSA* getMemorySSA() const { return MSSA; } in getMemorySSA()
H A DMemorySSA.h946 Result(std::unique_ptr<MemorySSA> &&MSSA) : MSSA(std::move(MSSA)) {}
948 MemorySSA &getMSSA() { return *MSSA; }
950 std::unique_ptr<MemorySSA> MSSA;
1001 MemorySSA &getMSSA() { return *MSSA; }
1002 const MemorySSA &getMSSA() const { return *MSSA; }
1010 std::unique_ptr<MemorySSA> MSSA;
1055 MemoryAccess *MA = MSSA->getMemoryAccess(I);
1081 BatchAAResults BAA(MSSA->getAA());
1086 BatchAAResults BAA(MSSA->getAA());
1092 BatchAAResults BAA(MSSA->getAA());
[all …]
/freebsd/contrib/llvm-project/llvm/include/llvm/Transforms/Utils/
H A DLoopUtils.h129 bool IsSink, Loop &L, MemorySSA &MSSA);
131 LLVM_ABI SinkAndHoistLICMFlags(bool IsSink, Loop &L, MemorySSA &MSSA);
207 LoopInfo *LI, MemorySSA *MSSA = nullptr);
213 LoopInfo &LI, MemorySSA *MSSA);
606 const MemorySSA &MSSA, AAResults &AA);
/freebsd/contrib/llvm-project/llvm/lib/CodeGen/
H A DInterleavedLoadCombinePass.cpp65 InterleavedLoadCombineImpl(Function &F, DominatorTree &DT, MemorySSA &MSSA, in InterleavedLoadCombineImpl()
68 : F(F), DT(DT), MSSA(MSSA), in InterleavedLoadCombineImpl()
83 MemorySSA &MSSA; member
1189 auto FMA = MSSA.getMemoryAccess(First); in combine()
1191 auto MADef = MSSA.getMemoryAccess(LI)->getDefiningAccess(); in combine()
1192 if (!MSSA.dominates(MADef, FMA)) in combine()
1225 auto MSSAU = MemorySSAUpdater(&MSSA); in combine()
1227 LI, nullptr, MSSA.getMemoryAccess(InsertionPoint))); in combine()
/freebsd/contrib/llvm-project/llvm/include/llvm/Transforms/Scalar/
H A DMemCpyOptimizer.h50 MemorySSA *MSSA = nullptr; variable
62 MemorySSA *MSSA);

12