Home | History | Annotate | Download | only in CodeGen

Lines Matching refs:ParentVNI

458                               const VNInfo *ParentVNI,
461 assert(ParentVNI && "Mapping NULL value");
463 assert(Edit->getParent().getVNInfoAt(Idx) == ParentVNI && "Bad Parent VNI");
473 Values.insert(std::make_pair(std::make_pair(RegIdx, ParentVNI->id), FP));
475 // This was the first time (RegIdx, ParentVNI) was mapped, and it is not
494 void SplitEditor::forceRecompute(unsigned RegIdx, const VNInfo &ParentVNI) {
495 ValueForcePair &VFP = Values[std::make_pair(RegIdx, ParentVNI.id)];
498 // ParentVNI was either unmapped or already complex mapped. Either way, just
628 VNInfo *ParentVNI,
647 LiveRangeEdit::Remat RM(ParentVNI);
670 return defValue(RegIdx, ParentVNI, Def, false);
696 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(Idx);
697 if (!ParentVNI) {
701 LLVM_DEBUG(dbgs() << ": valno " << ParentVNI->id << '\n');
705 VNInfo *VNI = defFromParent(OpenIdx, ParentVNI, Idx, *MI->getParent(), MI);
713 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(Idx);
714 if (!ParentVNI) {
718 LLVM_DEBUG(dbgs() << ": valno " << ParentVNI->id << '\n');
722 VNInfo *VNI = defFromParent(OpenIdx, ParentVNI, Idx, *MI->getParent(),
733 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(Last);
734 if (!ParentVNI) {
738 LLVM_DEBUG(dbgs() << ": valno " << ParentVNI->id);
739 VNInfo *VNI = defFromParent(OpenIdx, ParentVNI, Last, MBB,
764 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(Boundary);
765 if (!ParentVNI) {
769 LLVM_DEBUG(dbgs() << ": valno " << ParentVNI->id << '\n');
777 if (SpillMode && !SlotIndex::isSameInstr(ParentVNI->def, Idx) &&
779 forceRecompute(0, *ParentVNI);
780 defFromParent(0, ParentVNI, Idx, *MI->getParent(), MI);
784 VNInfo *VNI = defFromParent(0, ParentVNI, Boundary, *MI->getParent(),
795 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(Idx);
796 if (!ParentVNI) {
800 LLVM_DEBUG(dbgs() << ": valno " << ParentVNI->id << '\n');
804 VNInfo *VNI = defFromParent(0, ParentVNI, Idx, *MI->getParent(), MI);
814 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(Start);
815 if (!ParentVNI) {
820 VNInfo *VNI = defFromParent(0, ParentVNI, Start, MBB,
829 const VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(Start);
830 assert(ParentVNI == Edit->getParent().getVNInfoBefore(End) &&
836 if (ParentVNI)
837 forceRecompute(0, *ParentVNI);
954 // Aggregate VNIs having the same value as ParentVNI.
958 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(VNI->def);
959 EqualVNs[ParentVNI->id].insert(VNI);
962 // For VNI aggregation of each ParentVNI, collect dominated, i.e.,
965 VNInfo *ParentVNI = Parent->getValNumInfo(i);
966 if (!NotToHoistSet.count(ParentVNI->id))
968 SmallPtrSetIterator<VNInfo *> It1 = EqualVNs[ParentVNI->id].begin();
970 for (; It1 != EqualVNs[ParentVNI->id].end(); ++It1) {
972 for (++It2; It2 != EqualVNs[ParentVNI->id].end(); ++It2) {
988 forceRecompute(0, *ParentVNI);
998 /// the same ParentVNI and hoist the backcopies to the dominator BB.
1001 /// ParentVNI.
1007 // Track the nearest common dominator for all back-copies for each ParentVNI,
1008 // indexed by ParentVNI->id.
1011 // The total cost of all the back-copies for each ParentVNI.
1013 // The ParentVNI->id set for which hoisting back-copies are not beneficial
1022 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(VNI->def);
1023 assert(ParentVNI && "Parent not live at complement def");
1027 if (Edit->didRematerialize(ParentVNI))
1032 DomPair &Dom = NearestDom[ParentVNI->id];
1035 // instruction in the complement range. All other copies of ParentVNI
1037 if (VNI->def == ParentVNI->def) {
1044 if (Values.lookup(std::make_pair(0, ParentVNI->id)).getPointer()) {
1050 // First time we see ParentVNI. VNI dominates itself.
1066 Costs[ParentVNI->id] += MBFI.getBlockFreq(ValMBB);
1070 << VNI->def << " for parent " << ParentVNI->id << '@'
1071 << ParentVNI->def << " hoist to "
1082 VNInfo *ParentVNI = Parent->getValNumInfo(i);
1083 MachineBasicBlock *DefMBB = LIS.getMBBFromIndex(ParentVNI->def);
1087 MBFI.getBlockFreq(Dom.first) > Costs[ParentVNI->id]) {
1088 NotToHoistSet.insert(ParentVNI->id);
1093 defFromParent(0, ParentVNI, Last, *Dom.first,
1103 VNInfo *ParentVNI = Edit->getParent().getVNInfoAt(VNI->def);
1104 const DomPair &Dom = NearestDom[ParentVNI->id];
1106 NotToHoistSet.count(ParentVNI->id))
1109 forceRecompute(0, *ParentVNI);
1127 VNInfo *ParentVNI = S.valno;
1147 // The interval [Start;End) is continuously mapped to RegIdx, ParentVNI.
1153 ValueForcePair VFP = Values.lookup(std::make_pair(RegIdx, ParentVNI->id));
1197 if (BlockStart == ParentVNI->def) {
1199 assert(ParentVNI->isPHIDef() && "Non-phi defined at block start?");
1435 void SplitEditor::forceRecomputeVNI(const VNInfo &ParentVNI) {
1437 if (!ParentVNI.isPHIDef()) {
1439 forceRecompute(I, ParentVNI);
1446 Visited.insert(&ParentVNI);
1447 WorkList.push_back(&ParentVNI);
1477 for (const VNInfo *ParentVNI : Edit->getParent().valnos) {
1478 if (ParentVNI->isUnused())
1480 unsigned RegIdx = RegAssign.lookup(ParentVNI->def);
1481 defValue(RegIdx, ParentVNI, ParentVNI->def, true);
1485 if (Edit->didRematerialize(ParentVNI))
1486 forceRecomputeVNI(*ParentVNI);