https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82436

            Bug ID: 82436
           Summary: 465.tonto ICE in vect_get_slp_vect_defs, at
                    tree-vect-slp.c:3410
           Product: gcc
           Version: 8.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rguenth at gcc dot gnu.org
  Target Milestone: ---
            Target: i?86-*-*

With -Ofast -march=core-avx2 -flto -m32.

We are vectorizing

     do n=1,n_refl
       y = y + abs(F_z_(ext_refs(n)))
       w = w + abs(F_r_(ext_refs(n)))
     end do

from put_fcalc_plots which looks like the following before vectorization:

<bb 47> [84.24%] [count: INV]:
# _649 = PHI <1(46), _118(48)>
# y_lsm.44_396 = PHI <0.0(46), _113(48)>
# w_lsm.45_24 = PHI <0.0(46), _117(48)>
_104 = _103 * _649;
_105 = _102 + _104;
_107 = _105 * _106;
_108 = (sizetype) _107;
_109 = _101 + _108;
_651 = MEM[(struct reflection_type &)_109].f_pred;
_652 = MEM[(struct reflection_type &)_109].f_exp;
_653 = _651 - _652;
_655 = MEM[(struct reflection_type &)_109].f_sigma;
res_656 = _653 / _655;
_111 = ABS_EXPR <res_656>;
_113 = _111 + y_lsm.44_396;
res_648 = _653 / _652;
_115 = ABS_EXPR <res_648>;
_117 = _115 + w_lsm.45_24;
_118 = _649 + 1;
if (_118 > res_485)
  goto <bb 49>; [15.00%] [count: INV]
else
  goto <bb 48>; [85.00%] [count: INV]

<bb 48> [71.60%] [count: INV]:
goto <bb 47>; [100.00%] [count: INV]


all types are doubles.  The reflection_type is

   type reflection_type

   INT :: h
   ! Miller h index for the reflection

   INT :: k
   ! Miller k index for the reflection

   INT :: l
   ! Miller l index for the reflection

   REAL :: F_exp
   ! Experimental structure factor

   REAL :: F_sigma
   ! Experimental error in the structure factor

   CPX :: F_calc
   ! Calculated complex structure factor without including corrections

   REAL :: F_pred
   ! Calculated structure factor including scale and extinction corrections

   REAL :: I_exp
   ! Experimental intensity

   REAL :: I_sigma
   ! Experimental error in the intensity

   REAL :: I_pred
   ! Calculated intensity including scale and extinction corrections

   end type

where INT is int32_t and CPX is _Complex double.

Reply via email to