aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-07-25 17:57:37 +0000
committerChris Lattner <sabre@nondot.org>2009-07-25 17:57:37 +0000
commit4b49e5d55a628c57112998fff56e4af1ea3e046a (patch)
tree38254c8b04477e7e65acd6db5b85719f9c54fd64 /lib
parent7b2bb16c8131d3f3d665d69922d839ea9551879c (diff)
downloadexternal_llvm-4b49e5d55a628c57112998fff56e4af1ea3e046a.zip
external_llvm-4b49e5d55a628c57112998fff56e4af1ea3e046a.tar.gz
external_llvm-4b49e5d55a628c57112998fff56e4af1ea3e046a.tar.bz2
add the most expedient hack to fix PR4619, along with a testcase.
Thanks to Rafael for the great example. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77083 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/Target/TargetAsmInfo.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Target/TargetAsmInfo.cpp b/lib/Target/TargetAsmInfo.cpp
index 3edbe93..727c584 100644
--- a/lib/Target/TargetAsmInfo.cpp
+++ b/lib/Target/TargetAsmInfo.cpp
@@ -326,6 +326,11 @@ const Section *TargetAsmInfo::SectionForGlobal(const GlobalValue *GV) const {
// FIXME: Use mangler interface (PR4584).
std::string Name = Prefix+GV->getNameStr();
+
+ // Pick up the flags for the uniquing section.
+ // FIXME: HACK.
+ Flags |= getFlagsForNamedSection(Name.c_str());
+
return getNamedSection(Name.c_str(), Flags);
}
}