1 /* Test __builtin_{add,sub}_overflow on {,un}signed long int. */ 2 /* { dg-do run } */ 3 /* { dg-skip-if "" { ! run_expensive_tests } { "*" } { "-O0" "-O2" } } */ 4 5 typedef signed long int S; 6 typedef unsigned long int U; 7 #define COND 1 8 #define SHIFT ((__SIZEOF_LONG__ - 1) * __CHAR_BIT__) 9 #define S_MAX __LONG_MAX__ 10 #define S_MIN (-__LONG_MAX__ - 1) 11 #if __SIZEOF_LONG_LONG__ > __SIZEOF_LONG__ 12 typedef long long int W; 13 #elif __SIZEOF_INT128__ > __SIZEOF_LONG__ 14 typedef __int128 W; 15 #else 16 #undef COND 17 #define COND 0 18 #endif 19 #include "builtin-arith-overflow-7.c" 20