aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/ELFWriter.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-07-31 18:48:30 +0000
committerChris Lattner <sabre@nondot.org>2009-07-31 18:48:30 +0000
commita87dea4f8c546ca748f1777a8d1cabcc06515d91 (patch)
tree96993fb5aee8978a97581a0f79f86c61b2e1005f /lib/CodeGen/ELFWriter.cpp
parent5e5337a833c36b069723ff864c873a1ba4883b99 (diff)
switch off of 'Section' onto MCSection. We're not properly using
MCSection subclasses yet, but this is a step in the right direction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77708 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/ELFWriter.cpp')
-rw-r--r--lib/CodeGen/ELFWriter.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/CodeGen/ELFWriter.cpp b/lib/CodeGen/ELFWriter.cpp
index 230c5ac4be..c7438329e3 100644
--- a/lib/CodeGen/ELFWriter.cpp
+++ b/lib/CodeGen/ELFWriter.cpp
@@ -43,6 +43,7 @@
#include "llvm/CodeGen/MachineCodeEmitter.h"
#include "llvm/CodeGen/MachineConstantPool.h"
#include "llvm/MC/MCContext.h"
+#include "llvm/MC/MCSection.h"
#include "llvm/Target/TargetAsmInfo.h"
#include "llvm/Target/TargetData.h"
#include "llvm/Target/TargetELFWriterInfo.h"
@@ -334,8 +335,8 @@ void ELFWriter::EmitGlobal(const GlobalValue *GV) {
TM.getTargetLowering()->getObjFileLowering();
// Get the ELF section where this global belongs from TLOF
- const Section *S = TLOF.SectionForGlobal(GV, Mang, TM);
- unsigned SectionFlags = getElfSectionFlags(S->getKind());
+ const MCSection *S = TLOF.SectionForGlobal(GV, Mang, TM);
+ unsigned SectionFlags = getElfSectionFlags(((MCSectionELF*)S)->getKind());
// The symbol align should update the section alignment if needed
const TargetData *TD = TM.getTargetData();