summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp
diff options
context:
space:
mode:
authorRichard Osborne <richard@xmos.com>2009-08-18 17:58:17 +0000
committerRichard Osborne <richard@xmos.com>2009-08-18 17:58:17 +0000
commit934d61648b61a9775642b8db9ed42f0e92a28b57 (patch)
treef78834bf1ef1d97d48de46587ecf881138b31eef /llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp
parentd7f34337895312465d3e5b98fe98d6cc0ef83ddd (diff)
downloadbcm5719-llvm-934d61648b61a9775642b8db9ed42f0e92a28b57.tar.gz
bcm5719-llvm-934d61648b61a9775642b8db9ed42f0e92a28b57.zip
Put data with relocations in the same sections as data without relocations.
llvm-svn: 79351
Diffstat (limited to 'llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp')
-rw-r--r--llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp b/llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp
index 767611218a9..91cb11533df 100644
--- a/llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp
+++ b/llvm/lib/Target/XCore/XCoreTargetObjectFile.cpp
@@ -51,5 +51,11 @@ void XCoreTargetObjectFile::Initialize(MCContext &Ctx, const TargetMachine &TM){
MCSectionXCore::Create(".cp.rodata", MCSectionELF::SHT_PROGBITS,
MCSectionELF::SHF_ALLOC |
MCSectionXCore::SHF_CP_SECTION,
- SectionKind::getReadOnly(), false, getContext());
+ SectionKind::getReadOnlyWithRel(), false,
+ getContext());
+
+ // Dynamic linking is not supported. Data with relocations is placed in the
+ // same section as data without relocations.
+ DataRelSection = DataRelLocalSection = DataSection;
+ DataRelROSection = DataRelROLocalSection = ReadOnlySection;
}
OpenPOWER on IntegriCloud