summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/TargetLoweringObjectFile.cpp
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2010-01-07 19:44:05 +0000
committerEric Christopher <echristo@apple.com>2010-01-07 19:44:05 +0000
commit36ef435eca5bde7dddec79e8a095d3dc03d5294d (patch)
treee1d4d15b77b6e1ac84136844ee1ae4aa5a5b18b1 /llvm/lib/Target/TargetLoweringObjectFile.cpp
parent2a83635337eff9a688a003eec7fc3db9631bd294 (diff)
downloadbcm5719-llvm-36ef435eca5bde7dddec79e8a095d3dc03d5294d.tar.gz
bcm5719-llvm-36ef435eca5bde7dddec79e8a095d3dc03d5294d.zip
We need to put any kind of data with a relocation into a
not-readonly segment on darwin. llvm-svn: 92933
Diffstat (limited to 'llvm/lib/Target/TargetLoweringObjectFile.cpp')
-rw-r--r--llvm/lib/Target/TargetLoweringObjectFile.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Target/TargetLoweringObjectFile.cpp b/llvm/lib/Target/TargetLoweringObjectFile.cpp
index f887523c5b7..229b1d52c5e 100644
--- a/llvm/lib/Target/TargetLoweringObjectFile.cpp
+++ b/llvm/lib/Target/TargetLoweringObjectFile.cpp
@@ -922,7 +922,7 @@ const MCSection *
TargetLoweringObjectFileMachO::getSectionForConstant(SectionKind Kind) const {
// If this constant requires a relocation, we have to put it in the data
// segment, not in the text segment.
- if (Kind.isDataRel())
+ if (Kind.isDataRel() || Kind.isReadOnlyWithRel())
return ConstDataSection;
if (Kind.isMergeableConst4())
OpenPOWER on IntegriCloud