diff options
-rw-r--r-- | lib/MC/MCDwarf.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/lib/MC/MCDwarf.cpp b/lib/MC/MCDwarf.cpp index c55a964..cfd68c1 100644 --- a/lib/MC/MCDwarf.cpp +++ b/lib/MC/MCDwarf.cpp @@ -629,8 +629,6 @@ const MCSymbol &FrameEmitterImpl::EmitCIE(MCStreamer &streamer, unsigned lsdaEncoding) { MCContext &context = streamer.getContext(); const TargetAsmInfo &asmInfo = context.getTargetAsmInfo(); - const MCSection §ion = *asmInfo.getEHFrameSection(); - streamer.SwitchSection(§ion); MCSymbol *sectionStart; if (asmInfo.isFunctionEHFrameSymbolPrivate()) @@ -683,9 +681,8 @@ const MCSymbol &FrameEmitterImpl::EmitCIE(MCStreamer &streamer, // Personality augmentationLength += getSizeForEncoding(streamer, personalityEncoding); } - if (lsda) { + if (lsda) augmentationLength += 1; - } // Encoding of the FDE pointers augmentationLength += 1; @@ -698,10 +695,8 @@ const MCSymbol &FrameEmitterImpl::EmitCIE(MCStreamer &streamer, // Personality EmitPersonality(streamer, *personality, personalityEncoding); } - if (lsda) { - // LSDA Encoding - streamer.EmitIntValue(lsdaEncoding, 1); - } + if (lsda) + streamer.EmitIntValue(lsdaEncoding, 1); // LSDA Encoding // Encoding of the FDE pointers streamer.EmitIntValue(asmInfo.getFDEEncoding(UsingCFI), 1); @@ -831,6 +826,8 @@ void MCDwarfFrameEmitter::Emit(MCStreamer &streamer, bool usingCFI) { const MCContext &context = streamer.getContext(); const TargetAsmInfo &asmInfo = context.getTargetAsmInfo(); + const MCSection §ion = *asmInfo.getEHFrameSection(); + streamer.SwitchSection(§ion); MCSymbol *fdeEnd = NULL; DenseMap<CIEKey, const MCSymbol*> CIEStarts; |