public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/110957] New: -ffpe-trap and -ffpe-summary options issues
@ 2023-08-09  9:28 ubizjak at gmail dot com
  2023-08-13 20:19 ` [Bug fortran/110957] " anlauf at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: ubizjak at gmail dot com @ 2023-08-09  9:28 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 110957
           Summary: -ffpe-trap and -ffpe-summary options issues
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ubizjak at gmail dot com
  Target Milestone: ---

A couple of issues with -ffpe-trap and -ffpe-summary options:

a) Invalid argument report should be switched:

$ gfortran -ffpe-summary=aaa ac.f90
f951: Fatal Error: Argument to ‘-ffpe-trap’ is not valid: aaa
compilation terminated.

$ gfortran -ffpe-trap=aaa ac.f90
f951: Fatal Error: Argument to ‘-ffpe-summary’ is not valid: aaa
compilation terminated.


b) Specifying also -fno-trapping-math should be detected and handled

$ gfortran -ffpe-trap=invalid -fno-trapping-math ac.f90
[no diagnostics]

The issue b) should either report incompatibility between options, or force
-ftrapping-math (probably with a warning). Ideally, -ffpe-* should always set
flag_trapping_math, in case the compiler switches to no trapping math by
default in future.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-10-13 20:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-09  9:28 [Bug fortran/110957] New: -ffpe-trap and -ffpe-summary options issues ubizjak at gmail dot com
2023-08-13 20:19 ` [Bug fortran/110957] " anlauf at gcc dot gnu.org
2023-10-06 20:19 ` anlauf at gcc dot gnu.org
2023-10-13 20:07 ` cvs-commit at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).