Bug Report - HUGE() Function Crashes for Real (Kind=10) and Real (Kind=16)

Tobias Burnus burnus@net-b.de
Sat Jun 1 08:33:00 GMT 2013


Craig Dedo wrote:
> Today I discovered that the HUGE() function causes GFortran to crash if its
> argument is Real (Kind=10) or Real (Kind=16).  For both of these REAL kinds, the program
> generates a run-time SIGFPE floating-point exception.

It would have helped tremendously if you had stated that you compiled 
using "-ffpe-trap=overflow". With that flag, I can reproduce it on Linux.

(Thanks also to Tim Zeisloft of Lahey/Marlette Software for looking into 
it on Windows - and finding that "-ffpe-trap=overflow" caused the issue.)


That's now tracked at http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57496

Workaround:  Don't use "-ffpe-trap=overflow".

Tobias



More information about the Fortran mailing list