summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/SystemZ
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Target/SystemZ')
-rw-r--r--llvm/lib/Target/SystemZ/SystemZMCAsmInfo.cpp8
-rw-r--r--llvm/lib/Target/SystemZ/SystemZMCAsmInfo.h2
2 files changed, 6 insertions, 4 deletions
diff --git a/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.cpp b/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.cpp
index 1a0920609b1..f9ccc47b0b9 100644
--- a/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.cpp
+++ b/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.cpp
@@ -12,6 +12,7 @@
//===----------------------------------------------------------------------===//
#include "SystemZMCAsmInfo.h"
+#include "llvm/MC/MCContext.h"
#include "llvm/MC/MCSectionELF.h"
using namespace llvm;
@@ -21,7 +22,8 @@ SystemZMCAsmInfo::SystemZMCAsmInfo(const Target &T, const StringRef &TT) {
PCSymbol = ".";
}
-MCSection *SystemZMCAsmInfo::getNonexecutableStackSection(MCContext &Ctx) const{
- return MCSectionELF::Create(".note.GNU-stack", MCSectionELF::SHT_PROGBITS,
- 0, SectionKind::getMetadata(), false, Ctx);
+const MCSection *SystemZMCAsmInfo::
+getNonexecutableStackSection(MCContext &Ctx) const{
+ return Ctx.getELFSection(".note.GNU-stack", MCSectionELF::SHT_PROGBITS,
+ 0, SectionKind::getMetadata(), false);
}
diff --git a/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.h b/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.h
index 00cb99b34c0..87908f21f72 100644
--- a/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.h
+++ b/llvm/lib/Target/SystemZ/SystemZMCAsmInfo.h
@@ -22,7 +22,7 @@ namespace llvm {
struct SystemZMCAsmInfo : public MCAsmInfo {
explicit SystemZMCAsmInfo(const Target &T, const StringRef &TT);
- virtual MCSection *getNonexecutableStackSection(MCContext &Ctx) const;
+ virtual const MCSection *getNonexecutableStackSection(MCContext &Ctx) const;
};
} // namespace llvm
OpenPOWER on IntegriCloud