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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
           Keywords|                            |ra
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2023-07-04
      Known to fail|                            |12.1.0, 14.0, 5.1.0, 7.1.0
            Summary|[11/12/13/14 regression]    |[11/12/13/14 Regression] an
                   |Suboptimal codegen for 128  |extra mov when doing 128bit
                   |bits multiplication on      |multiply
                   |x86_64                      |
      Known to work|                            |4.9.4

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
It is an older regression though.
```
#include <stdint.h>

void mulx64(uint64_t *x, uint64_t *t)
{
    __uint128_t r = (__uint128_t)*x * 0x9E3779B97F4A7C15ull;
    *t = (uint64_t)r ^ (uint64_t)( r >> 64 );
}
```

It is just an extra mov.

Also the mulx should have allowed the register allocator to do better but it
was worse ...

Reply via email to