------- Comment #7 from domob at gcc dot gnu dot org 2008-09-10 19:04 ------- The problem is that gfc_interpret_float does not set the default mpfr precision to the value for its kind parameter but leaves the setting that is already present. This is presumably the reason why inserting the dummy variable changed the test's behaviour, because this made caused the precision to be set to that for KIND=4 for the dummy variable. Adding this initialization fixes the problem.
I will submit a patch shortly. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36214