[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gcc-fortran
Subject:    Re: [gfortran,patch, RFC] Allow coredump and backtrace on runtime   error
From:       Tobias Burnus <burnus () net-b ! de>
Date:       2006-11-28 9:29:02
Message-ID: 456C015E.6010103 () net-b ! de
[Download RAW message or body]

Hi,

Craig Powers wrote:
> Tobias Burnus wrote:
>>  Counter example: ifort (with trace enabled by default):
>> forrtl: No such file or directory
>> forrtl: severe (29): file not found, unit 77, file
>> /dev/shm/not-existing.dat [...]
>> a.out              00000000004025A9  Unknown               Unknown 
>> Unknown
> In my experience, ifort will always produce a trace, but only give
> useable routine/line/source info if you specify a flag, I think
> -traceback.  But I haven't combed through the options to see if
> there's something to turn off the automatic trace.
Yes, the flag is -traceback (default is -notraceback). If you don't want
to have the stacktrace you need to set FOR_DISABLE_STACK_TRACE=true.

But my point was actually only that for for most library errors a stack
trace is not needed and even worse clutters the output that one has
difficulties to find the actual error message ("file not found").
Especially since gfortran prints (almost?) always the file and line
number in the error message.

(For arithmetic errors and similar, one currently gets a core dump
[unless ulimit -c 0] and thus a stack trace is also not needed by
default for this case, I think.)

Tobias

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic