https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93385
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |diagnostic --- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> --- In fact if we add -Wuninitialized, we get the warning: t2.c: In function ‘main’: t2.c:7:8: warning: ‘d’ is used uninitialized in this function [-Wuninitialized] 7 | d %= (unsigned) d; | ^~~~~~~~~~~~ t2.c:4:1: note: ‘d’ was declared here 4 | c (unsigned __int128 d) | ^ --- CUT --- Here is a testcase without __int128 so other targets: char a, b; static inline int c (unsigned int d) { char e = 0; d %= (unsigned short) d; e -= 0; __builtin_strncpy (&a, &e, 1); return e + b ; } int main (void) { c (~0); return 0; }