This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: ia64 symbol_ref_flags usage
On Thu, Apr 17, 2003 at 01:44:00PM +0200, Andreas Schwab wrote:
> Surely not. All the GPREL22 relocations below were LTOFF22 relocations
> previously.
Argh. Sorry for misinterpreting earlier results. There really
is an ld relaxation problem, but this isn't it. This was a latent
bug in the in_small_data_p predicate.
r~
* config/ia64/ia64.c (ia64_in_small_data_p): Disallow strings.
Index: config/ia64/ia64.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/ia64/ia64.c,v
retrieving revision 1.218
diff -u -p -u -r1.218 ia64.c
--- config/ia64/ia64.c 16 Apr 2003 19:53:13 -0000 1.218
+++ config/ia64/ia64.c 17 Apr 2003 19:53:12 -0000
@@ -7389,6 +7389,10 @@ ia64_in_small_data_p (exp)
if (TARGET_NO_SDATA)
return false;
+ /* We want to merge strings, so we never consider them small data. */
+ if (TREE_CODE (exp) == STRING_CST)
+ return false;
+
if (TREE_CODE (exp) == VAR_DECL && DECL_SECTION_NAME (exp))
{
const char *section = TREE_STRING_POINTER (DECL_SECTION_NAME (exp));