diff options
author | Evan Cheng <evan.cheng@apple.com> | 2008-01-31 09:59:15 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2008-01-31 09:59:15 +0000 |
commit | 1c6c16ea11b8c589be0bf3b598bd7a6b30d71968 (patch) | |
tree | 033727a857bdf480ebca015b589e570e87c28ca3 /llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp | |
parent | 0592cf7e7406e41ce3658bf829e3ccdc31ed162c (diff) | |
download | bcm5719-llvm-1c6c16ea11b8c589be0bf3b598bd7a6b30d71968.tar.gz bcm5719-llvm-1c6c16ea11b8c589be0bf3b598bd7a6b30d71968.zip |
Add an extra operand to LABEL nodes which distinguishes between debug, EH, or misc labels. This fixes the EH breakage. However I am not convinced this is *the* solution.
llvm-svn: 46609
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp b/llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp index ff8b359470a..fa218263bc2 100644 --- a/llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp +++ b/llvm/lib/Target/PowerPC/PPCRegisterInfo.cpp @@ -712,11 +712,11 @@ void PPCRegisterInfo::emitPrologue(MachineFunction &MF) const { // Prepare for frame info. unsigned FrameLabelId = 0; - // Skip over the labels which mark the beginning of the function. + // Skip over the debug labels which mark the beginning of the function. if (MMI && MMI->needsFrameInfo()) { unsigned NumLabels = 0; while (NumLabels <= 1 && - MBBI != MBB.end() && MBBI->getOpcode() == PPC::LABEL) { + MBBI != MBB.end() && MBBI->isDebugLabel()) { ++NumLabels; ++MBBI; } @@ -786,7 +786,7 @@ void PPCRegisterInfo::emitPrologue(MachineFunction &MF) const { if (MMI && MMI->needsFrameInfo()) { // Mark effective beginning of when frame pointer becomes valid. FrameLabelId = MMI->NextLabelID(); - BuildMI(MBB, MBBI, TII.get(PPC::LABEL)).addImm(FrameLabelId); + BuildMI(MBB, MBBI, TII.get(PPC::LABEL)).addImm(FrameLabelId).addImm(0); } // Adjust stack pointer: r1 += NegFrameSize. @@ -870,7 +870,7 @@ void PPCRegisterInfo::emitPrologue(MachineFunction &MF) const { // Mark effective beginning of when frame pointer is ready. unsigned ReadyLabelId = MMI->NextLabelID(); - BuildMI(MBB, MBBI, TII.get(PPC::LABEL)).addImm(ReadyLabelId); + BuildMI(MBB, MBBI, TII.get(PPC::LABEL)).addImm(ReadyLabelId).addImm(0); MachineLocation FPDst(HasFP ? (IsPPC64 ? PPC::X31 : PPC::R31) : (IsPPC64 ? PPC::X1 : PPC::R1)); |