Lines Matching defs:Cand
730 bool RAGreedy::growRegion(GlobalSplitCandidate &Cand) {
733 SmallVectorImpl<unsigned> &ActiveBlocks = Cand.ActiveBlocks;
768 if (Cand.PhysReg) {
769 if (!addThroughConstraints(Cand.Intf, NewBlocks))
809 bool RAGreedy::calcCompactRegion(GlobalSplitCandidate &Cand) {
815 Cand.reset(IntfCache, MCRegister::NoRegister);
821 SpillPlacer->prepare(Cand.LiveBundles);
823 // The static split cost will be zero since Cand.Intf reports no interference.
825 if (!addSplitConstraints(Cand.Intf, Cost)) {
830 if (!growRegion(Cand)) {
837 if (!Cand.LiveBundles.any()) {
843 for (int I : Cand.LiveBundles.set_bits())
871 BlockFrequency RAGreedy::calcGlobalSplitCost(GlobalSplitCandidate &Cand,
874 const BitVector &LiveBundles = Cand.LiveBundles;
883 Cand.Intf.moveToBlock(BC.Number);
893 for (unsigned Number : Cand.ActiveBlocks) {
900 Cand.Intf.moveToBlock(Number);
901 if (Cand.Intf.hasInterference()) {
949 GlobalSplitCandidate &Cand = GlobalCand[CandIn];
950 IntvIn = Cand.IntvIdx;
951 Cand.Intf.moveToBlock(Number);
952 IntfIn = Cand.Intf.first();
958 GlobalSplitCandidate &Cand = GlobalCand[CandOut];
959 IntvOut = Cand.IntvIdx;
960 Cand.Intf.moveToBlock(Number);
961 IntfOut = Cand.Intf.last();
997 GlobalSplitCandidate &Cand = GlobalCand[CandIn];
998 IntvIn = Cand.IntvIdx;
999 Cand.Intf.moveToBlock(Number);
1000 IntfIn = Cand.Intf.first();
1005 GlobalSplitCandidate &Cand = GlobalCand[CandOut];
1006 IntvOut = Cand.IntvIdx;
1007 Cand.Intf.moveToBlock(Number);
1008 IntfOut = Cand.Intf.last();
1026 // - Candidate intervals can be assigned to Cand.PhysReg.
1124 GlobalSplitCandidate &Cand = GlobalCand[NumCands];
1125 Cand.reset(IntfCache, PhysReg);
1127 SpillPlacer->prepare(Cand.LiveBundles);
1129 if (!addSplitConstraints(Cand.Intf, Cost)) {
1145 if (!growRegion(Cand)) {
1153 if (!Cand.LiveBundles.any()) {
1158 Cost += calcGlobalSplitCost(Cand, Order);
1161 for (int I : Cand.LiveBundles.set_bits())
1205 GlobalSplitCandidate &Cand = GlobalCand[BestCand];
1206 if (unsigned B = Cand.getBundles(BundleCand, BestCand)) {
1208 Cand.IntvIdx = SE->openIntv();
1209 LLVM_DEBUG(dbgs() << "Split for " << printReg(Cand.PhysReg, TRI) << " in "
1210 << B << " bundles, intv " << Cand.IntvIdx << ".\n");
1217 GlobalSplitCandidate &Cand = GlobalCand.front();
1218 assert(!Cand.PhysReg && "Compact region has no physreg");
1219 if (unsigned B = Cand.getBundles(BundleCand, 0)) {
1221 Cand.IntvIdx = SE->openIntv();
1223 << " bundles, intv " << Cand.IntvIdx << ".\n");