https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78314

--- Comment #11 from Richard Earnshaw <rearnsha at gcc dot gnu.org> ---
(In reply to nsz from comment #10)
> it turns out the ieee_* functions are allowed in const expressions so they
> need to work at compile time too (see bug 78449), which of course won't work
> if they need runtime detection.
> 
> so now compile-time and runtime behaviour of ieee_support_halting is
> different.
> 
> so far no fortran expert clarified what is the expected semantics when you
> can only decide this at runtime (e.g. it might be better to always return
> false on targets that may not implement trapping, rather than report things
> inconsistently compile- vs runtime).
> 
> (i think this bug can be closed, but then the other one has to be reopened).

Well the 'safe' answer in this case, when you can't be sure whether or not
run-time traps will occur is surely to say 'no, they can't'.  You might then
get redundant code in the app that can't be reached, but at least it will still
execute correctly.

Reply via email to