[Bug libfortran/66458] Loading libgfortran.so changes the FPU exception flags
fxcoudert at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sun Jul 5 12:13:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66458
Francois-Xavier Coudert <fxcoudert at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2015-07-05
CC| |fxcoudert at gcc dot gnu.org
Assignee|unassigned at gcc dot gnu.org |fxcoudert at gcc dot gnu.org
Target Milestone|--- |6.0
Ever confirmed|0 |1
--- Comment #4 from Francois-Xavier Coudert <fxcoudert at gcc dot gnu.org> ---
(In reply to kargl from comment #3)
> You're loading a dynamic library that has a constructor that is
> executed to set up the library's internal state. If you're loading
> libraries and you want a specific FPU state, then you'll need to
> save and reset the state.
Yet, if not FPE-specific option was passed, there is no good reason for us to
mess with the FPU state.
Anyway, currently something's a bit suboptimal here. For example, if a program
is compiled with -ffpe-trap, we're gonna call set_fpu() twice: once from the
constructor, then again from the main program. That doesn't seem right.
More information about the Gcc-bugs
mailing list