diff options
author | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2015-05-20 18:25:40 +0000 |
---|---|---|
committer | Duncan P. N. Exon Smith <dexonsmith@apple.com> | 2015-05-20 18:25:40 +0000 |
commit | fd28abcf15b433a4e36cee68a2f4bf7db6ce52a9 (patch) | |
tree | cde72d7f19c7055b0bc9505cf8cfef0bf7d9df83 /llvm/lib/MC/MCELFStreamer.cpp | |
parent | fd8b64eea0d179b9bd5ab2499cfe2a136535a889 (diff) | |
download | bcm5719-llvm-fd28abcf15b433a4e36cee68a2f4bf7db6ce52a9.tar.gz bcm5719-llvm-fd28abcf15b433a4e36cee68a2f4bf7db6ce52a9.zip |
MC: Use MCSymbol in LocalCommon, NFC
Switch from MCSymbolData to MCSymbol in LocalCommon.
llvm-svn: 237816
Diffstat (limited to 'llvm/lib/MC/MCELFStreamer.cpp')
-rw-r--r-- | llvm/lib/MC/MCELFStreamer.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/llvm/lib/MC/MCELFStreamer.cpp b/llvm/lib/MC/MCELFStreamer.cpp index 0286fd5aefd..fe54dcbd83c 100644 --- a/llvm/lib/MC/MCELFStreamer.cpp +++ b/llvm/lib/MC/MCELFStreamer.cpp @@ -319,7 +319,7 @@ void MCELFStreamer::EmitCommonSymbol(MCSymbol *Symbol, uint64_t Size, AssignSection(Symbol, Section); - struct LocalCommon L = {&SD, Size, ByteAlignment}; + struct LocalCommon L = {Symbol, Size, ByteAlignment}; LocalCommons.push_back(L); } else { SD.setCommon(Size, ByteAlignment); @@ -630,17 +630,16 @@ void MCELFStreamer::Flush() { for (std::vector<LocalCommon>::const_iterator i = LocalCommons.begin(), e = LocalCommons.end(); i != e; ++i) { - MCSymbolData *SD = i->SD; + const MCSymbol &Symbol = *i->Symbol; uint64_t Size = i->Size; unsigned ByteAlignment = i->ByteAlignment; - const MCSymbol &Symbol = SD->getSymbol(); const MCSection &Section = Symbol.getSection(); MCSectionData &SectData = getAssembler().getOrCreateSectionData(Section); new MCAlignFragment(ByteAlignment, 0, 1, ByteAlignment, &SectData); MCFragment *F = new MCFillFragment(0, 0, Size, &SectData); - SD->setFragment(F); + Symbol.getData().setFragment(F); // Update the maximum alignment of the section if necessary. if (ByteAlignment > SectData.getAlignment()) |