Stop find_split_point from clobbering constant pool entries
Richard Henderson
rth@redhat.com
Sun Nov 2 07:20:00 GMT 2003
On Sat, Nov 01, 2003 at 11:33:16AM +0000, Richard Sandiford wrote:
> /* A MEM is allowed to be shared if its address is constant.
>
> We used to allow sharing of MEMs which referenced
> virtual_stack_vars_rtx or virtual_incoming_args_rtx, but
> that can lose. instantiate_virtual_regs will not unshare
> the MEMs, and combine may change the structure of the address
> because it looks safe and profitable in one context, but
> in some other context it creates unrecognizable RTL. */
> if (CONSTANT_ADDRESS_P (XEXP (x, 0)))
Personally I think this is bogus. IIRC this can cause problems in
rare cases for amd64 where
(set (reg) (mem (64-bit-constant))
is valid for reg=%rax, but for a different destination register we
have to reload the constant. Which causes reload to run into shared
rtl problems.
IMO we should just remove this special case.
r~
More information about the Gcc-patches
mailing list