GNU Binutils with patches for OS216
Revision | cd78ea777c35c497fcc0f20d162789296dc0a44d (tree) |
---|---|
Time | 2015-07-22 19:37:50 |
Author | H.J. Lu <hjl.tools@gmai...> |
Commiter | H.J. Lu |
Mark global with hidden attribute
GCC 5 will generate a relocation for protected symbol:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65248
when compiling for a shared library. It is undefined to access protected
symbol in IFUNC selector function inside a shared library.
PR gold/18628
* testsuite/ifuncdep2.c (global): Change protected to hidden.
* testsuite/ifuncmod1.c (global): Likewise.
* testsuite/ifuncmod5.c (global): Likewise.
@@ -1,3 +1,10 @@ | ||
1 | +2015-07-22 H.J. Lu <hongjiu.lu@intel.com> | |
2 | + | |
3 | + PR gold/18628 | |
4 | + * testsuite/ifuncdep2.c (global): Change protected to hidden. | |
5 | + * testsuite/ifuncmod1.c (global): Likewise. | |
6 | + * testsuite/ifuncmod5.c (global): Likewise. | |
7 | + | |
1 | 8 | 2015-07-22 Alan Modra <amodra@gmail.com> |
2 | 9 | |
3 | 10 | * aarch64.cc (try_fix_erratum_843419_optimized): Warning fix. |
@@ -2,7 +2,7 @@ | ||
2 | 2 | |
3 | 3 | #include "ifunc-sel.h" |
4 | 4 | |
5 | -int global __attribute__ ((visibility ("protected"))) = -1; | |
5 | +int global __attribute__ ((visibility ("hidden"))) = -1; | |
6 | 6 | |
7 | 7 | static int |
8 | 8 | one (void) |
@@ -6,7 +6,7 @@ | ||
6 | 6 | */ |
7 | 7 | #include "ifunc-sel.h" |
8 | 8 | |
9 | -int global __attribute__ ((visibility ("protected"))) = -1; | |
9 | +int global __attribute__ ((visibility ("hidden"))) = -1; | |
10 | 10 | |
11 | 11 | static int |
12 | 12 | one (void) |
@@ -1,7 +1,7 @@ | ||
1 | 1 | /* Test STT_GNU_IFUNC symbols without direct function call. */ |
2 | 2 | #include "ifunc-sel.h" |
3 | 3 | |
4 | -int global __attribute__ ((visibility ("protected"))) = -1; | |
4 | +int global __attribute__ ((visibility ("hidden"))) = -1; | |
5 | 5 | |
6 | 6 | static int |
7 | 7 | one (void) |