https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95276
Thomas Koenig <tkoenig at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|WAITING |NEW --- Comment #4 from Thomas Koenig <tkoenig at gcc dot gnu.org> --- The error is locale-dependent, at least somewhat. With the test case I posted: $ LANG="" gcc -S -O2 w-posted.i In function 'ztoa_big', inlined from 'write_z' at w-posted.i:6499:11: w-posted.i:6484:6: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=] 6484 | *q = '\0'; | ~~~^~~~~~ w-posted.i: In function 'write_z': w-posted.i:6495:8: note: at offset 0 to object 'itoa_buf' with size 33 declared here 6495 | char itoa_buf[((sizeof (GFC_REAL_16)) * 2 + 1)]; | ^~~~~~~~ $ LANG="de_DE.UTF-8" gcc -S -O2 w-posted.i w-posted.i: In Funktion »write_z«: w-posted.i:6484:6: Warnung: Schreiben von 140096374336960 Byte in eine Region der Größe 1 [-Wstringop-overflow=] 6484 | *q = '\0'; | ~~~^~~~~~ w-posted.i:6495:8: Anmerkung: bei Offset 0 zum Objekt »itoa_buf« mit Größe 33 wurde hier deklariert 6495 | char itoa_buf[((sizeof (GFC_REAL_16)) * 2 + 1)]; So, probably reading from uninitialized memory somewhere. I think this should be enough to confirm this.