https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90628
--- Comment #2 from Jeremy <gcc.hall at gmail dot com> --- (In reply to Marc Glisse from comment #1) > Thanks for the report. > (next time, please include a complete, compilable example, with the > #includes, int main, etc) Sorry, here is a complete program:- #include <stdio.h> int main( int argc, const __attribute__ ((unused)) char *argv[] ) { const int a = argc; const int b = argc; if( __builtin_mul_overflow( a, b, &a ) ) puts( "overflow" ); printf( "square = %d\n", a ); }