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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |rguenth at gcc dot 
gnu.org
   Target Milestone|---                         |10.0

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
I will have a look.

Before the rev. we expanded from

  <bb 2> [local count: 1073741825]:
  _1 = BIT_FIELD_REF <x_7(D), 64, 0>;
  _2 = BIT_FIELD_REF <y_8(D), 64, 0>;
  _3 = _1 + _2;
  _4 = BIT_FIELD_REF <x_7(D), 64, 64>;
  z_6 = {_3, _4};

while after we do

  <bb 2> [local count: 1073741824]:
  _1 = BIT_FIELD_REF <x_4(D), 64, 0>;
  _2 = BIT_FIELD_REF <y_5(D), 64, 0>;
  _3 = _1 + _2;
  _7 = {_3, _3};
  z_6 = VEC_PERM_EXPR <x_4(D), _7, { 2, 1 }>;


Testcase with the same behavior before and after the rev which we should
improve together with fixing the regression:

typedef double __v2df __attribute__ ((__vector_size__ (16)));
typedef long __v2di __attribute__ ((__vector_size__ (16)));

__v2df
_mm_add_sd (__v2df x, __v2df y)
{
  double tem = x[0] + y[0];
  return __builtin_shuffle ( x, (__v2df) { tem, tem }, (__v2di) { 2, 1 } );
}

Reply via email to