• Home
  • Raw
  • Download

Lines Matching refs:PN

49 isSafeToSpeculatePHIUsers(PHINode &PN, DominatorTree &DT,  in isSafeToSpeculatePHIUsers()  argument
52 auto *PhiBB = PN.getParent(); in isSafeToSpeculatePHIUsers()
57 for (Use &U : PN.uses()) { in isSafeToSpeculatePHIUsers()
203 PHINode &PN, SmallDenseMap<PHINode *, int, 16> &CostSavingsMap, in isSafeAndProfitableToSpeculateAroundPHI() argument
218 for (int i : llvm::seq<int>(0, PN.getNumIncomingValues())) { in isSafeAndProfitableToSpeculateAroundPHI()
219 auto *IncomingC = dyn_cast<ConstantInt>(PN.getIncomingValue(i)); in isSafeAndProfitableToSpeculateAroundPHI()
224 if (!IncomingConstantBlocks.insert(PN.getIncomingBlock(i)).second) in isSafeAndProfitableToSpeculateAroundPHI()
240 LLVM_DEBUG(dbgs() << " Free: " << PN << "\n"); in isSafeAndProfitableToSpeculateAroundPHI()
247 if (!isSafeToSpeculatePHIUsers(PN, DT, PotentialSpecSet, UnsafeSet)) { in isSafeAndProfitableToSpeculateAroundPHI()
248 LLVM_DEBUG(dbgs() << " Unsafe PHI: " << PN << "\n"); in isSafeAndProfitableToSpeculateAroundPHI()
254 for (Use &U : PN.uses()) { in isSafeAndProfitableToSpeculateAroundPHI()
329 << ": " << PN << "\n"); in isSafeAndProfitableToSpeculateAroundPHI()
330 CostSavingsMap[&PN] = TotalMatCost - TotalFoldedCost; in isSafeAndProfitableToSpeculateAroundPHI()
351 for (auto *PN : PNs) in visitPHIUsersAndDepsInPostOrder() local
352 for (Use &U : PN->uses()) { in visitPHIUsersAndDepsInPostOrder()
437 for (auto *PN : PNs) { in findProfitablePHIs() local
439 for (Use &U : PN->uses()) in findProfitablePHIs()
441 PNUserCountMap[PN] = UserSet.size(); in findProfitablePHIs()
443 UserToPNMap.insert({UI, {}}).first->second.push_back(PN); in findProfitablePHIs()
496 for (auto *PN : llvm::make_range(UserPNsSplitIt, UserPNs.end())) { in findProfitablePHIs() local
498 for (Use &U : PN->uses()) in findProfitablePHIs()
505 int CostSavings = CostSavingsMap.find(PN)->second; in findProfitablePHIs()
507 LLVM_DEBUG(dbgs() << " Not profitable, speculation cost: " << *PN in findProfitablePHIs()
519 SpecPNs.push_back(PN); in findProfitablePHIs()
520 for (Use &U : PN->uses()) { in findProfitablePHIs()
760 [&](PHINode *PN) { in tryToSpeculatePHIs() argument
762 *PN, CostSavingsMap, PotentialSpecSet, in tryToSpeculatePHIs()
817 while (auto *PN = dyn_cast<PHINode>(&*BBI)) { in run() local
818 PNs.push_back(PN); in run()