1 /* PR tree-optimization/98474 */ 2 3 #ifdef __SIZEOF_INT128__ 4 typedef __uint128_t T; 5 #define N (__SIZEOF_INT128__ * __CHAR_BIT__ / 2) 6 #else 7 typedef unsigned long long T; 8 #define N (__SIZEOF_LONG_LONG__ * __CHAR_BIT__ / 2) 9 #endif 10 11 __attribute__ ((noipa)) void foo(T * x)12foo (T *x) 13 { 14 *x += ((T) 1) << (N + 1); 15 } 16 17 int main()18main () 19 { 20 T a = ((T) 1) << (N + 1); 21 T b = a; 22 T n; 23 foo (&b); 24 n = b; 25 while (n >= a) 26 n -= a; 27 if ((int) (n >> N) != 0) 28 __builtin_abort (); 29 return 0; 30 } 31