diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2020-07-26 19:36:28 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2020-07-26 19:36:28 +0000 |
commit | cfca06d7963fa0909f90483b42a6d7d194d01e08 (patch) | |
tree | 209fb2a2d68f8f277793fc8df46c753d31bc853b /llvm/lib/MC/MCSectionCOFF.cpp | |
parent | 706b4fc47bbc608932d3b491ae19a3b9cde9497b (diff) |
Notes
Diffstat (limited to 'llvm/lib/MC/MCSectionCOFF.cpp')
-rw-r--r-- | llvm/lib/MC/MCSectionCOFF.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/llvm/lib/MC/MCSectionCOFF.cpp b/llvm/lib/MC/MCSectionCOFF.cpp index f0c06f70bd734..387bf2c884e58 100644 --- a/llvm/lib/MC/MCSectionCOFF.cpp +++ b/llvm/lib/MC/MCSectionCOFF.cpp @@ -38,12 +38,12 @@ void MCSectionCOFF::PrintSwitchToSection(const MCAsmInfo &MAI, const Triple &T, raw_ostream &OS, const MCExpr *Subsection) const { // standard sections don't require the '.section' - if (ShouldOmitSectionDirective(SectionName, MAI)) { - OS << '\t' << getSectionName() << '\n'; + if (ShouldOmitSectionDirective(getName(), MAI)) { + OS << '\t' << getName() << '\n'; return; } - OS << "\t.section\t" << getSectionName() << ",\""; + OS << "\t.section\t" << getName() << ",\""; if (getCharacteristics() & COFF::IMAGE_SCN_CNT_INITIALIZED_DATA) OS << 'd'; if (getCharacteristics() & COFF::IMAGE_SCN_CNT_UNINITIALIZED_DATA) @@ -61,7 +61,7 @@ void MCSectionCOFF::PrintSwitchToSection(const MCAsmInfo &MAI, const Triple &T, if (getCharacteristics() & COFF::IMAGE_SCN_MEM_SHARED) OS << 's'; if ((getCharacteristics() & COFF::IMAGE_SCN_MEM_DISCARDABLE) && - !isImplicitlyDiscardable(SectionName)) + !isImplicitlyDiscardable(getName())) OS << 'D'; OS << '"'; @@ -111,3 +111,7 @@ bool MCSectionCOFF::UseCodeAlign() const { bool MCSectionCOFF::isVirtualSection() const { return getCharacteristics() & COFF::IMAGE_SCN_CNT_UNINITIALIZED_DATA; } + +StringRef MCSectionCOFF::getVirtualSectionKind() const { + return "IMAGE_SCN_CNT_UNINITIALIZED_DATA"; +} |