aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH.J. Lu <hongjiu.lu@intel.com>2011-06-15 15:50:22 +0000
committerH.J. Lu <hjl@gcc.gnu.org>2011-06-15 08:50:22 -0700
commit6beec6813aa23a06f56ba73b7fbfafe2e2662c26 (patch)
tree779a54fd8a5693709c3b3dfe306e6278090e252c
parent85ce937577ea720114fab3a8e5993be0cc6f6d7f (diff)
downloadgcc-6beec6813aa23a06f56ba73b7fbfafe2e2662c26.zip
gcc-6beec6813aa23a06f56ba73b7fbfafe2e2662c26.tar.gz
gcc-6beec6813aa23a06f56ba73b7fbfafe2e2662c26.tar.bz2
Mark __dso_handle hidden if assembler supports it.
2011-06-15 H.J. Lu <hongjiu.lu@intel.com> PR c++/49412 * decl.c (get_dso_handle_node): Mark __dso_handle hidden if assembler supports hidden visibility. From-SVN: r175080
-rw-r--r--gcc/cp/ChangeLog6
-rw-r--r--gcc/cp/decl.c5
2 files changed, 11 insertions, 0 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 88bb8fb..9ed5086 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,9 @@
+2011-06-15 H.J. Lu <hongjiu.lu@intel.com>
+
+ PR c++/49412
+ * decl.c (get_dso_handle_node): Mark __dso_handle hidden if
+ assembler supports hidden visibility.
+
2011-06-14 Jason Merrill <jason@redhat.com>
PR c++/49107
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
index 3ccefb9..29edbe3 100644
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -6435,6 +6435,11 @@ get_dso_handle_node (void)
dso_handle_node = declare_global_var (get_identifier ("__dso_handle"),
ptr_type_node);
+#ifdef HAVE_GAS_HIDDEN
+ DECL_VISIBILITY (dso_handle_node) = VISIBILITY_HIDDEN;
+ DECL_VISIBILITY_SPECIFIED (dso_handle_node) = 1;
+#endif
+
return dso_handle_node;
}