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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |pinskia at gcc dot 
gnu.org

--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Mine.

Even the simple one:
```
int
signed_f1(int v)
{
  int b_5;
  int _7;
  int _9;

  b_5 = v>>(sizeof(v)*8 - 1);
  _9 = b_5 | 1;
  _7 = v * _9;
  return _7;
}
```

is not detected.

First version without any nop_converts added:

(simplify
 (mult:c @0 (bit_ior:c (rshift @0 INTEGER_CST@1) integer_onep))
 (if (!TYPE_UNSIGNED (TREE_TYPE (@0))
      && wi::to_wide (@1) == element_precision (type) - 1)
  (abs @0)))

Reply via email to