diff options
Diffstat (limited to 'lib/Target/TargetAsmInfo.cpp')
-rw-r--r-- | lib/Target/TargetAsmInfo.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Target/TargetAsmInfo.cpp b/lib/Target/TargetAsmInfo.cpp index 02e01be5df..51042dac95 100644 --- a/lib/Target/TargetAsmInfo.cpp +++ b/lib/Target/TargetAsmInfo.cpp @@ -364,8 +364,10 @@ TargetAsmInfo::SelectSectionForGlobal(const GlobalValue *GV, const Section * TargetAsmInfo::getSectionForMergableConstant(uint64_t Size, unsigned ReloInfo) const { - // FIXME: Support data.rel stuff someday - // Lame default implementation. Calculate the section name for machine const. + if (ReloInfo == 0) + if (const Section *S = getReadOnlySection()) + return S; + return getDataSection(); } |