This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/49628] [4.7 Regression] 447.dealII in SPEC CPU 2006 failed to build
- From: "rguenth at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 4 Jul 2011 15:06:54 +0000
- Subject: [Bug middle-end/49628] [4.7 Regression] 447.dealII in SPEC CPU 2006 failed to build
- Auto-submitted: auto-generated
- References: <bug-49628-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49628
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |irar at gcc dot gnu.org
--- Comment #4 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-07-04 15:06:51 UTC ---
Vectorizing the loop
<bb 8>:
# __position_11 = PHI <__position_34(9), __position$_M_current_15(7)>
D.2964_46 = __x_copy.values[0];
__position_11->values[0] = D.2964_46;
D.2964_51 = __x_copy.values[1];
__position_11->values[1] = D.2964_51;
D.2964_56 = __x_copy.values[2];
__position_11->values[2] = D.2964_56;
__position_34 = __position_11 + 24;
if (D.2961_29 != __position_34)
goto <bb 9>;
else
goto <bb 10>;
<bb 9>:
goto <bb 8>;
I wonder where we are supposed to set GROUP_SIZE here and how it possibly
can connect to my change ... ah, the invariant loads from __x_copy.values
no longer will inhibit vectorization early. The group is now indeed
the __x_copy.values[] loads.
The following fixes it (or rather, avoids looking at this group):
Index: gcc/tree-vect-data-refs.c
===================================================================
--- gcc/tree-vect-data-refs.c (revision 175802)
+++ gcc/tree-vect-data-refs.c (working copy)
@@ -1495,12 +1495,19 @@ vect_enhance_data_refs_alignment (loop_v
&& GROUP_FIRST_ELEMENT (stmt_info) != stmt)
continue;
+ /* For invariant accesses there is nothing to enhance. */
+ if (integer_zerop (DR_STEP (dr)))
+ continue;
+
supportable_dr_alignment = vect_supportable_dr_alignment (dr, true);
do_peeling = vector_alignment_reachable_p (dr);
if (do_peeling)