This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/71779] [5/6/7 regression] isl miscompiled with -mabi=ilp32
- From: "bernd.edlinger at hotmail dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 29 Jul 2016 18:45:49 +0000
- Subject: [Bug rtl-optimization/71779] [5/6/7 regression] isl miscompiled with -mabi=ilp32
- Auto-submitted: auto-generated
- References: <bug-71779-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71779
--- Comment #16 from Bernd Edlinger <bernd.edlinger at hotmail dot de> ---
Alternative patch, that looks like it fixes this issue (but not the other bug).
Note: it generates one instruction more than the first patch, thus
paradoxical subregs trigger at least one other bug, and are harder
to optimize than zero extend.
Index: emit-rtl.c
===================================================================
--- emit-rtl.c (revision 238815)
+++ emit-rtl.c (working copy)
@@ -1155,7 +1155,7 @@ set_reg_attrs_from_value (rtx reg, rtx x)
|| (GET_CODE (x) == SUBREG && subreg_lowpart_p (x)))
{
#if defined(POINTERS_EXTEND_UNSIGNED)
- if (((GET_CODE (x) == SIGN_EXTEND && POINTERS_EXTEND_UNSIGNED)
+ if (((GET_CODE (x) != ZERO_EXTEND && POINTERS_EXTEND_UNSIGNED)
|| (GET_CODE (x) != SIGN_EXTEND && ! POINTERS_EXTEND_UNSIGNED))
&& !targetm.have_ptr_extend ())
can_be_reg_pointer = false;
Andreas, can you confirm that the isl-code is working with
this patch too?
Thanks
Bernd.