| 1 |
/* PR c/102989 */ |
| 2 |
/* { dg-do compile { target bitint } } */ |
| 3 |
/* { dg-options "-O2 -std=gnu23 -w" } */ |
| 4 |
|
| 5 |
_BitInt(37) |
| 6 |
foo (_BitInt(37) x, _BitInt(37) y) |
| 7 |
{ |
| 8 |
_BitInt(37) w; |
| 9 |
__asm ("# %0 %1 %2 %3" : "=r" (w) : "r" (x), "r" (x + y), "g" (68719476735wb)); |
| 10 |
return w; |
| 11 |
} |
| 12 |
|
| 13 |
#if __BITINT_MAXWIDTH__ >= 125 |
| 14 |
_BitInt(125) |
| 15 |
bar (_BitInt(125) x, _BitInt(125) y) |
| 16 |
{ |
| 17 |
_BitInt(125) w; |
| 18 |
__asm ("# %0 %1 %2 %3" : "=g" (w) : "g" (x), "g" (x + y), "g" (21267647932558653966460912964485513215wb)); |
| 19 |
return w; |
| 20 |
} |
| 21 |
#endif |
| 22 |
|
| 23 |
#if __BITINT_MAXWIDTH__ >= 575 |
| 24 |
_BitInt(575) |
| 25 |
baz (_BitInt(575) x, _BitInt(575) y) |
| 26 |
{ |
| 27 |
_BitInt(575) w; |
| 28 |
__asm ("# %0 %1 %2 %3" : "=g" (w) : "g" (x), "g" (x + y), "g" (61832600368276133515125630254911797508782837275302959978515764023224306276632966792579100265310761247399417856504034834837841258576687802491886538775473291979151693037174783wb)); |
| 29 |
return w; |
| 30 |
} |
| 31 |
#endif |