diff --git a/libgfortran/ChangeLog b/libgfortran/ChangeLog index 04a2b923f194..ffd6cfd3cbff 100644 --- a/libgfortran/ChangeLog +++ b/libgfortran/ChangeLog @@ -1,3 +1,8 @@ +2015-08-07 Francois-Xavier Coudert + + PR libfortran/66458 + * runtime/main.c (init): Only call set_fpu() if requested by user. + 2015-08-06 Francois-Xavier Coudert * runtime/compile_options.c (set_options): Fix typos. diff --git a/libgfortran/runtime/main.c b/libgfortran/runtime/main.c index 3c66a30fff2e..cb8e518b5829 100644 --- a/libgfortran/runtime/main.c +++ b/libgfortran/runtime/main.c @@ -263,7 +263,11 @@ init (void) init_variables (); init_units (); - set_fpu (); + + /* If (and only if) the user asked for it, set up the FPU state. */ + if (options.fpe != 0) + set_fpu (); + init_compile_options (); #ifdef DEBUG