This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: x86 PIC regressions
- To: Robert Lipe <robertl at dgii dot com>, "H.J. Lu" <hjl at lucon dot org>
- Subject: Re: x86 PIC regressions
- From: Richard Henderson <rth at cygnus dot com>
- Date: Wed, 2 Sep 1998 11:03:08 -0700
- Cc: egcs at cygnus dot com, egcs-patches at cygnus dot com
- References: <19980827135954.O3677@dgii.com> <m0zE4KM-00038xC@ocean.lucon.org> <19980902013530.K1741@dgii.com>
- Reply-To: Richard Henderson <rth at cygnus dot com>
On Wed, Sep 02, 1998 at 01:35:30AM -0500, Robert Lipe wrote:
> /play/egcs/gcc/testsuite/gcc.c-torture/execute/930106-1.c:27:
> internal error--unrecognizable insn:
> (insn 12 11 13 (set:DF (reg:DF 23)
> (mem/u:DF (symbol_ref/u:SI ("*.LC0")))) -1 (nil)
> (expr_list:REG_EQUAL (const_double:DF (mem/u:DF (symbol_ref/u:SI ("*.LC0")))
> 0 0 1073790976)
> (nil)))
> /play/egcs/gcc/toplev.c:1360: Internal compiler error in function fatal_insn
>
> FAIL: gcc.c-torture/execute/930106-1.c compilation, -O0
The following fixes it.
r~
* varasm.c (force_const_mem): Validize the address of the memory.
Index: varasm.c
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/varasm.c,v
retrieving revision 1.37
diff -c -p -d -r1.37 varasm.c
*** varasm.c 1998/07/06 22:40:02 1.37
--- varasm.c 1998/09/02 18:00:39
*************** force_const_mem (mode, x)
*** 3512,3517 ****
--- 3512,3520 ----
CONSTANT_POOL_ADDRESS_P (XEXP (def, 0)) = 1;
current_function_uses_const_pool = 1;
+ /* Validize after we have set CONSTANT_POOL_ADDRESS_P. */
+ def = validize_mem (def);
+
if (outer_function_chain == 0)
if (GET_CODE (x) == CONST_DOUBLE)
{