This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] delegitimize pic constructs in more places (PR rtl-optimization/23098)
On Fri, Sep 02, 2005 at 12:16:30PM -0700, Richard Henderson wrote:
> On Fri, Sep 02, 2005 at 11:35:46AM -0700, Ian Lance Taylor wrote:
> > Whereas the calls in dwarf2out.c do pass a MEM, not an address.
>
> Inconsistently. All but one instance in dwarf2out.c pass addresses.
Actually, I think 2 instances in dwarf2out.c pass MEM and one passes
address.
ix86_delegitimize_address in many places differentiates between
orig_x being a MEM or an address, should all those checks be simply removed?
I.e. should in addition to deleting that if (MEM_P (x)) x = XEXP (x, 0);
at the beginning say
if (GET_CODE (x) == UNSPEC
&& ((XINT (x, 1) == UNSPEC_GOT && GET_CODE (orig_x) == MEM)
|| (XINT (x, 1) == UNSPEC_GOTOFF && GET_CODE (orig_x) != MEM)))
be modified into
if (GET_CODE (x) == UNSPEC
&& (XINT (x, 1) == UNSPEC_GOT || (XINT (x, 1) == UNSPEC_GOTOFF)))
?
Jakub