diff options
author | Guillaume Chatelet <gchatelet@google.com> | 2022-11-24 15:23:06 +0000 |
---|---|---|
committer | Guillaume Chatelet <gchatelet@google.com> | 2022-11-24 16:09:44 +0000 |
commit | 6c09ea3fdd6fb8001a079bc892aa095e9693b932 (patch) | |
tree | 1c803f13b31cbeb2135389f77c82a6f3b5e96480 /llvm/lib/MC/MCDwarf.cpp | |
parent | b9e3f5f864fb1944be60725aca400a9332ac6aa5 (diff) | |
download | llvm-6c09ea3fdd6fb8001a079bc892aa095e9693b932.zip llvm-6c09ea3fdd6fb8001a079bc892aa095e9693b932.tar.gz llvm-6c09ea3fdd6fb8001a079bc892aa095e9693b932.tar.bz2 |
[Alignment][NFC] Use Align in MCStreamer::emitValueToAlignment
Differential Revision: https://reviews.llvm.org/D138674
Diffstat (limited to 'llvm/lib/MC/MCDwarf.cpp')
-rw-r--r-- | llvm/lib/MC/MCDwarf.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/MC/MCDwarf.cpp b/llvm/lib/MC/MCDwarf.cpp index 2368326..b761a96 100644 --- a/llvm/lib/MC/MCDwarf.cpp +++ b/llvm/lib/MC/MCDwarf.cpp @@ -1686,7 +1686,7 @@ const MCSymbol &FrameEmitterImpl::EmitCIE(const MCDwarfFrameInfo &Frame) { InitialCFAOffset = CFAOffset; // Padding - Streamer.emitValueToAlignment(IsEH ? 4 : MAI->getCodePointerSize()); + Streamer.emitValueToAlignment(Align(IsEH ? 4 : MAI->getCodePointerSize())); Streamer.emitLabel(sectionEnd); return *sectionStart; @@ -1763,8 +1763,8 @@ void FrameEmitterImpl::EmitFDE(const MCSymbol &cieStart, // The size of a .eh_frame section has to be a multiple of the alignment // since a null CIE is interpreted as the end. Old systems overaligned // .eh_frame, so we do too and account for it in the last FDE. - unsigned Align = LastInSection ? asmInfo->getCodePointerSize() : PCSize; - Streamer.emitValueToAlignment(Align); + unsigned Alignment = LastInSection ? asmInfo->getCodePointerSize() : PCSize; + Streamer.emitValueToAlignment(Align(Alignment)); Streamer.emitLabel(fdeEnd); } @@ -1869,7 +1869,7 @@ void MCDwarfFrameEmitter::Emit(MCObjectStreamer &Streamer, MCAsmBackend *MAB, if (Frame.CompactUnwindEncoding == 0) continue; if (!SectionEmitted) { Streamer.switchSection(MOFI->getCompactUnwindSection()); - Streamer.emitValueToAlignment(AsmInfo->getCodePointerSize()); + Streamer.emitValueToAlignment(Align(AsmInfo->getCodePointerSize())); SectionEmitted = true; } NeedsEHFrameSection |= |