summaryrefslogtreecommitdiffstats
path: root/lib/Target/SystemZ
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-04-08 21:26:26 +0000
committerChris Lattner <sabre@nondot.org>2010-04-08 21:26:26 +0000
commit74aae4726a66733c5872588287535a984f9a94c7 (patch)
tree881707df3911fb308e40f805a973d89773ec36d3 /lib/Target/SystemZ
parent2d16a67b9466102ae479f0027cedc1a20dd493d1 (diff)
downloadexternal_llvm-74aae4726a66733c5872588287535a984f9a94c7.zip
external_llvm-74aae4726a66733c5872588287535a984f9a94c7.tar.gz
external_llvm-74aae4726a66733c5872588287535a984f9a94c7.tar.bz2
move elf section uniquing to MCContext. Along the way
merge XCore's section into MCSectionELF git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100812 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/SystemZ')
-rw-r--r--lib/Target/SystemZ/SystemZMCAsmInfo.cpp8
-rw-r--r--lib/Target/SystemZ/SystemZMCAsmInfo.h2
2 files changed, 6 insertions, 4 deletions
diff --git a/lib/Target/SystemZ/SystemZMCAsmInfo.cpp b/lib/Target/SystemZ/SystemZMCAsmInfo.cpp
index 1a09206..f9ccc47 100644
--- a/lib/Target/SystemZ/SystemZMCAsmInfo.cpp
+++ b/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/lib/Target/SystemZ/SystemZMCAsmInfo.h b/lib/Target/SystemZ/SystemZMCAsmInfo.h
index 00cb99b..87908f2 100644
--- a/lib/Target/SystemZ/SystemZMCAsmInfo.h
+++ b/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