mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-16 12:24:03 +00:00
MachineModuleInfo: Turn nested std::pairs into a proper struct.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203414 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -473,15 +473,12 @@ void StackColoring::remapInstructions(DenseMap<int, int> &SlotRemap) {
|
||||
MachineModuleInfo *MMI = &MF->getMMI();
|
||||
|
||||
// Remap debug information that refers to stack slots.
|
||||
MachineModuleInfo::VariableDbgInfoMapTy &VMap = MMI->getVariableDbgInfo();
|
||||
for (MachineModuleInfo::VariableDbgInfoMapTy::iterator VI = VMap.begin(),
|
||||
VE = VMap.end(); VI != VE; ++VI) {
|
||||
const MDNode *Var = VI->first;
|
||||
if (!Var) continue;
|
||||
std::pair<unsigned, DebugLoc> &VP = VI->second;
|
||||
if (SlotRemap.count(VP.first)) {
|
||||
DEBUG(dbgs()<<"Remapping debug info for ["<<Var->getName()<<"].\n");
|
||||
VP.first = SlotRemap[VP.first];
|
||||
for (auto &VI : MMI->getVariableDbgInfo()) {
|
||||
if (!VI.Var)
|
||||
continue;
|
||||
if (SlotRemap.count(VI.Slot)) {
|
||||
DEBUG(dbgs()<<"Remapping debug info for ["<<VI.Var->getName()<<"].\n");
|
||||
VI.Slot = SlotRemap[VI.Slot];
|
||||
FixedDbg++;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user