Lines Matching defs:VNI
123 SibValueInfo(unsigned Reg, VNInfo *VNI)
125 SpillReg(Reg), SpillVNI(VNI), SpillMBB(nullptr), DefMI(nullptr) {}
171 void propagateSiblingValue(SibValueMap::iterator, VNInfo *VNI = nullptr);
175 void eliminateRedundantSpills(LiveInterval &LI, VNInfo *VNI);
348 /// @param VNI Dependent value, or NULL to propagate to all saved dependents.
350 VNInfo *VNI) {
353 // When VNI is non-NULL, add it to SVI's deps, and only propagate to that.
355 if (VNI) {
356 FirstDeps.push_back(VNI);
357 SVI->second.Deps.push_back(VNI);
370 TinyPtrVector<VNInfo*> *Deps = VNI ? &FirstDeps : &SVI->second.Deps;
371 VNI = nullptr;
507 // List of (Reg, VNI) that have been inserted into SibValues, but need to be
514 VNInfo *VNI;
515 std::tie(Reg, VNI) = WorkList.pop_back_val();
516 DEBUG(dbgs() << " " << PrintReg(Reg) << ':' << VNI->id << '@' << VNI->def
520 SVI = SibValues.find(VNI);
524 if (VNI->isPHIDef()) {
526 if (VNI->def == OrigVNI->def) {
539 // jointly dominate VNI->def. This is not optimal since VNI may actually
583 // Propagate to all inserted PHIs, not just VNI.
591 MachineInstr *MI = LIS.getInstructionFromIndex(VNI->def);
598 LiveQueryResult SrcQ = SrcLI.Query(VNI->def);
612 propagateSiblingValue(SVI, VNI);
660 VNInfo *VNI = *VI;
661 if (VNI->isUnused())
664 if (!VNI->isPHIDef()) {
665 DefMI = LIS.getInstructionFromIndex(VNI->def);
669 if (VNI->isPHIDef() || DefMI->isCopy()) {
670 VNInfo *OrigVNI = OrigLI.getVNInfoAt(VNI->def);
672 if (OrigVNI->def != VNI->def)
673 DefMI = traceSiblingValue(Reg, VNI, OrigVNI);
675 if (DefMI && Edit->checkRematerializable(VNI, DefMI, AA)) {
676 DEBUG(dbgs() << "Value " << PrintReg(Reg) << ':' << VNI->id << '@'
677 << VNI->def << " may remat from " << *DefMI);
687 VNInfo *VNI = SpillLI.getVNInfoAt(Idx.getRegSlot());
688 assert(VNI && VNI->def == Idx.getRegSlot() && "Not defined by copy");
689 SibValueMap::iterator I = SibValues.find(VNI);
696 if (!SVI.AllDefsAreReloads && SVI.SpillVNI == VNI)
755 /// eliminateRedundantSpills - SLI:VNI is known to be on the stack. Remove any
757 void InlineSpiller::eliminateRedundantSpills(LiveInterval &SLI, VNInfo *VNI) {
758 assert(VNI && "Missing value");
760 WorkList.push_back(std::make_pair(&SLI, VNI));
765 std::tie(LI, VNI) = WorkList.pop_back_val();
768 << VNI->id << '@' << VNI->def << " in " << *LI << '\n');
774 // Add all of VNI's live range to StackInt.
775 StackInt->MergeValueInAsValue(*LI, VNI, StackInt->getValNumInfo(0));
778 // Find all spills and copies of VNI.
786 if (LI->getVNInfoAt(Idx) != VNI)
820 /// markValueUsed - Remember that VNI failed to rematerialize, so its defining
822 void InlineSpiller::markValueUsed(LiveInterval *LI, VNInfo *VNI) {
824 WorkList.push_back(std::make_pair(LI, VNI));
826 std::tie(LI, VNI) = WorkList.pop_back_val();
827 if (!UsedValues.insert(VNI))
830 if (VNI->isPHIDef()) {
831 MachineBasicBlock *MBB = LIS.getMBBFromIndex(VNI->def);
842 MachineInstr *MI = LIS.getInstructionFromIndex(VNI->def);
847 VNInfo *SnipVNI = SnipLI.getVNInfoAt(VNI->def.getRegSlot(true));
958 VNInfo *VNI = *I;
959 if (VNI->isUnused() || VNI->isPHIDef() || UsedValues.count(VNI))
961 MachineInstr *MI = LIS.getInstructionFromIndex(VNI->def);
1134 if (VNInfo *VNI = LR->getVNInfoAt(Idx))
1135 LR->removeValNo(VNI);
1246 if (VNInfo *VNI = OldLI.getVNInfoAt(Idx.getRegSlot(true)))
1247 if (SlotIndex::isSameInstr(Idx, VNI->def))
1248 Idx = VNI->def;