This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/55142] [4.8 Regression] internal compiler error: in plus_constant, at explow.c:88
- From: "ebotcazou at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 08 Nov 2012 23:21:44 +0000
- Subject: [Bug middle-end/55142] [4.8 Regression] internal compiler error: in plus_constant, at explow.c:88
- Auto-submitted: auto-generated
- References: <bug-55142-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55142
--- Comment #29 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-11-08 23:21:44 UTC ---
> So for POINTERS_EXTEND_UNSIGNED > 0, we should transform
>
> (zero_extend:DI (plus:SI (FOO:SI) (const_int Y)))
>
> in such a way that it won't cause ICE and zero-extend the
> result. For X32, we just need to generate
>
> (plus:SI (REG:SI) (const_int Y))
The ICE is a minor detail, the real issue is convert_memory_address_addr_space
and PR middle-end/49721. The unmodified compiler generates the same
problematic instructions for the full testcase without -fPIC. It's clear that
Richard's change, aka the un-sign-extension of sizetype constants, is an
earthquake here.