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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2024-01-13
             Status|UNCONFIRMED                 |NEW

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Confirmed.

Testcase which shows what something is wrong with the original value:
```
typedef _BitInt(255) B;

[[gnu::noipa]]
B
foo(int s)
{
  B a = 0;
  a = (-(B)3) >> s;
  return a;
}

int
main(void)
{
  B x = foo(51);
  unsigned long *a = (unsigned long *)&x;
  __builtin_printf("%lx\n", a[0]);
  __builtin_printf("%lx\n", a[1]);
  __builtin_printf("%lx\n", a[2]);
  __builtin_printf("%lx\n", a[3]);
  //if (x != -1)
  //  __builtin_abort();
  return 0;
}
```

Reply via email to