forked from OSchip/llvm-project
[AArch64] Stop creating unnecessary label MCSymbols for each Windows unwind opcode. NFC.
These labels aren't needed in the ARM version of WinEH tables, as each unwind opcode maps to a specific instruction (each opcode is assumed to represent one instruction), and the written tables don't contain offsets like on x86_64. Differential Revision: https://reviews.llvm.org/D125369
This commit is contained in:
parent
490cd14fe6
commit
2d8ce08b09
|
@ -72,8 +72,7 @@ void AArch64TargetWinCOFFStreamer::emitARM64WinUnwindCode(unsigned UnwindCode,
|
|||
WinEH::FrameInfo *CurFrame = S.EnsureValidWinFrameInfo(SMLoc());
|
||||
if (!CurFrame)
|
||||
return;
|
||||
MCSymbol *Label = S.emitCFILabel();
|
||||
auto Inst = WinEH::Instruction(UnwindCode, Label, Reg, Offset);
|
||||
auto Inst = WinEH::Instruction(UnwindCode, /*Label=*/nullptr, Reg, Offset);
|
||||
if (InEpilogCFI)
|
||||
CurFrame->EpilogMap[CurrentEpilog].push_back(Inst);
|
||||
else
|
||||
|
@ -177,7 +176,8 @@ void AArch64TargetWinCOFFStreamer::emitARM64WinCFIPrologEnd() {
|
|||
|
||||
MCSymbol *Label = S.emitCFILabel();
|
||||
CurFrame->PrologEnd = Label;
|
||||
WinEH::Instruction Inst = WinEH::Instruction(Win64EH::UOP_End, Label, -1, 0);
|
||||
WinEH::Instruction Inst =
|
||||
WinEH::Instruction(Win64EH::UOP_End, /*Label=*/nullptr, -1, 0);
|
||||
auto it = CurFrame->Instructions.begin();
|
||||
CurFrame->Instructions.insert(it, Inst);
|
||||
}
|
||||
|
@ -199,8 +199,8 @@ void AArch64TargetWinCOFFStreamer::emitARM64WinCFIEpilogEnd() {
|
|||
return;
|
||||
|
||||
InEpilogCFI = false;
|
||||
MCSymbol *Label = S.emitCFILabel();
|
||||
WinEH::Instruction Inst = WinEH::Instruction(Win64EH::UOP_End, Label, -1, 0);
|
||||
WinEH::Instruction Inst =
|
||||
WinEH::Instruction(Win64EH::UOP_End, /*Label=*/nullptr, -1, 0);
|
||||
CurFrame->EpilogMap[CurrentEpilog].push_back(Inst);
|
||||
CurrentEpilog = nullptr;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue