Lines Matching defs:LocIndex

204 struct LocIndex {
245 LocIndex(u32_location_t Location, u32_index_t Index)
252 template<typename IntT> static LocIndex fromRawInteger(IntT ID) {
254 "Cannot convert raw integer to LocIndex");
262 return LocIndex(Reg, 0).getAsRawInteger();
269 uint64_t Start = LocIndex(Location, 0).getAsRawInteger();
270 uint64_t End = LocIndex(Location + 1, 0).getAsRawInteger();
276 using VarLocsInRange = SmallSet<LocIndex::u32_index_t, 32>;
277 // Vector of all `LocIndex`s for a given VarLoc; the same Location should not
280 using LocIndices = SmallVector<LocIndex, 2>;
789 /// 2) Given a LocIndex, look up the unique associated VarLoc.
797 SmallDenseMap<LocIndex::u32_location_t, std::vector<VarLoc>> Loc2Vars;
806 SmallVector<LocIndex::u32_location_t, 4> Locations;
816 return (RegNo < LocIndex::kFirstInvalidRegLocation) ||
817 (LocIndex::kFirstVirtualRegLocation <= RegNo);
821 Locations.push_back(LocIndex::kSpillLocation);
823 Locations.push_back(LocIndex::kWasmLocation);
825 LocIndex::u32_location_t Loc = LocIndex::kEntryValueBackupLocation;
828 Locations.push_back(LocIndex::kUniversalLocation);
829 for (LocIndex::u32_location_t Location : Locations) {
832 {Location, static_cast<LocIndex::u32_index_t>(Vars.size())});
845 const VarLoc &operator[](LocIndex ID) const {
856 LocIndex LocationID; ///< Location number for the transfer dest.
861 using InstToEntryLocMap = std::multimap<const MachineInstr *, LocIndex>;
928 LocIndex::u32_location_t Location);
961 return LocIndex::indexRangeForLocation(getVarLocs(), Reg);
966 return LocIndex::indexRangeForLocation(getVarLocs(),
967 LocIndex::kSpillLocation);
973 return LocIndex::indexRangeForLocation(
974 getVarLocs(), LocIndex::kEntryValueBackupLocation);
979 return LocIndex::indexRangeForLocation(getVarLocs(),
980 LocIndex::kWasmLocation);
1037 LocIndex OldVarID, TransferKind Kind,
1128 for (LocIndex ID : IDs)
1158 LocIndex::u32_location_t Location) {
1160 for (LocIndex::u32_index_t ID : KillSet) {
1161 const VarLoc &VL = VarLocIDs[LocIndex(Location, ID)];
1165 for (LocIndex ID : VLI)
1175 Regs.insert(LocIndex::kUniversalLocation);
1178 LocIndex Idx = LocIndex::fromRawInteger(ID);
1188 for (LocIndex ID : VarLocIDs)
1212 auto It = CollectFrom.find(LocIndex::rawIndexForReg(SortedRegs.front()));
1218 uint64_t FirstIndexForReg = LocIndex::rawIndexForReg(Reg);
1219 uint64_t FirstInvalidIndex = LocIndex::rawIndexForReg(Reg + 1);
1224 LocIndex ItIdx = LocIndex::fromRawInteger(*It);
1228 assert(LI.back().Location == LocIndex::kUniversalLocation &&
1244 LocIndex::rawIndexForReg(LocIndex::kFirstRegLocation);
1246 LocIndex::rawIndexForReg(LocIndex::kFirstInvalidRegLocation);
1248 LocIndex::rawIndexForReg(LocIndex::kFirstVirtualRegLocation);
1252 uint32_t FoundReg = LocIndex::fromRawInteger(*It).Location;
1260 uint64_t NextRegIndex = LocIndex::rawIndexForReg(FoundReg + 1);
1388 const VarLoc &VL = VarLocIDs[LocIndex::fromRawInteger(ID)];
1464 uint64_t FirstIndex = LocIndex::rawIndexForReg(LocIndex::kUniversalLocation);
1466 LocIndex::rawIndexForReg(LocIndex::kUniversalLocation + 1);
1470 LocIndex RegIdx = LocIndex::fromRawInteger(*It);
1487 LocIndex Idx = LocIndex(LocIndex::kUniversalLocation, ID);
1519 VarLocMap &VarLocIDs, LocIndex OldVarID, TransferKind Kind,
1650 OpenRanges.erase(KillSet, VarLocIDs, LocIndex::kUniversalLocation);
1674 LocIndex Idx = LocIndex::fromRawInteger(ID);
1680 OpenRanges.erase(KillSet, VarLocIDs, LocIndex::kWasmLocation);
1776 LocIndex Idx = LocIndex::fromRawInteger(ID);
1798 OpenRanges.erase(KillSet, VarLocIDs, LocIndex::kSpillLocation);
1823 LocIndex Idx = LocIndex::fromRawInteger(ID);
1890 LocIndex Idx = LocIndex::fromRawInteger(ID);
1911 LocIndex Idx = LocIndex::fromRawInteger(ID);
2081 LocIndex Idx = LocIndex::fromRawInteger(ID);