Module Name: src
Committed By: christos
Date: Tue Apr 2 02:59:50 UTC 2019
Modified Files:
src/external/gpl3/gcc.old/dist/gcc/config/vax: vax.c
Log Message:
Compiling some files with -fPIC and -O2 ends up having global
symbols classified as local in pic mode, and that ends up with PC32
relocations "movl *psp, %rx" (/bin/sh parse.c). Treat pic code as
shared libraries to avoid classifying common initialized symbols
as local. Thanks to thorpej@ for his help.
To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/external/gpl3/gcc.old/dist/gcc/config/vax/vax.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/gpl3/gcc.old/dist/gcc/config/vax/vax.c
diff -u src/external/gpl3/gcc.old/dist/gcc/config/vax/vax.c:1.6 src/external/gpl3/gcc.old/dist/gcc/config/vax/vax.c:1.7
--- src/external/gpl3/gcc.old/dist/gcc/config/vax/vax.c:1.6 Wed Aug 1 20:03:02 2018
+++ src/external/gpl3/gcc.old/dist/gcc/config/vax/vax.c Mon Apr 1 22:59:50 2019
@@ -114,6 +114,18 @@ static bool vax_mode_dependent_address_p
#undef TARGET_OPTION_OVERRIDE
#define TARGET_OPTION_OVERRIDE vax_option_override
+#if TARGET_ELF
+#undef TARGET_BINDS_LOCAL_P
+#define TARGET_BINDS_LOCAL_P vax_elf_binds_local_p
+
+static bool
+vax_elf_binds_local_p (const_tree exp)
+{
+ return default_binds_local_p_3 (exp, (flag_shlib | flag_pic) != 0,
+ true, false, false);
+}
+#endif
+
struct gcc_target targetm = TARGET_INITIALIZER;
/* Set global variables as needed for the options enabled. */