MIR Serialization: Serialize the machine function's liveins.

Reviewers: Duncan P. N. Exon Smith


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243288 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Alex Lorenz
2015-07-27 17:42:45 +00:00
parent b7abbca1dd
commit a5da4f1f8d
8 changed files with 165 additions and 1 deletions

View File

@@ -201,6 +201,15 @@ void MIRPrinter::convert(yaml::MachineFunction &MF,
printReg(PreferredReg, VReg.PreferredRegister, TRI);
MF.VirtualRegisters.push_back(VReg);
}
// Print the live ins.
for (auto I = RegInfo.livein_begin(), E = RegInfo.livein_end(); I != E; ++I) {
yaml::MachineFunctionLiveIn LiveIn;
printReg(I->first, LiveIn.Register, TRI);
if (I->second)
printReg(I->second, LiveIn.VirtualRegister, TRI);
MF.LiveIns.push_back(LiveIn);
}
}
void MIRPrinter::convert(yaml::MachineFrameInfo &YamlMFI,