http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59227
--- Comment #11 from Francois-Xavier Coudert <fxcoudert at gcc dot gnu.org> --- So, it looks like the same code that works fine in an external C program, is miscompiled in libgfortran's _gfortran_erfc_scaled_r16. Do you agree? Can you remove the __builtin_printf call inside foo() in comment #6, and compile with the same flags as used to compile libgfortran? For me, that would be "-std=gnu99 -fcx-fortran-rules -ffunction-sections -fdata-sections -g -O2" Just to be sureā¦