summaryrefslogtreecommitdiffstats
path: root/contrib/llvm/lib/MC/MCSectionCOFF.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/llvm/lib/MC/MCSectionCOFF.cpp')
-rw-r--r--contrib/llvm/lib/MC/MCSectionCOFF.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/contrib/llvm/lib/MC/MCSectionCOFF.cpp b/contrib/llvm/lib/MC/MCSectionCOFF.cpp
index b8373f4..f2dd47d 100644
--- a/contrib/llvm/lib/MC/MCSectionCOFF.cpp
+++ b/contrib/llvm/lib/MC/MCSectionCOFF.cpp
@@ -64,6 +64,9 @@ void MCSectionCOFF::PrintSwitchToSection(const MCAsmInfo &MAI,
OS << 'n';
if (getCharacteristics() & COFF::IMAGE_SCN_MEM_SHARED)
OS << 's';
+ if ((getCharacteristics() & COFF::IMAGE_SCN_MEM_DISCARDABLE) &&
+ !isImplicitlyDiscardable(SectionName))
+ OS << 'D';
OS << '"';
if (getCharacteristics() & COFF::IMAGE_SCN_LNK_COMDAT) {
OpenPOWER on IntegriCloud