* RH5.0 arithmetic traps.
@ 1998-03-31 16:23 Harvey J. Stein
1998-03-31 16:37 ` David Alan Gilbert
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Harvey J. Stein @ 1998-03-31 16:23 UTC (permalink / raw)
To: axp-list
I have an application which builds & runs fine on linux/alpha RH 4.2,
but when I try to build & run it on linux/alpha RH 5.0 it fails. It
seems to build fine, but when I run it I get an arithmetic trap reported
by the kernel, and the program crashes with a floating point
exception.
Anyone have any ideas what might be wrong and/or how to fix it?
Thanks,
--
Harvey J. Stein
Berger Financial Research
hjstein@bfr.co.il
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: RH5.0 arithmetic traps.
1998-03-31 16:23 RH5.0 arithmetic traps Harvey J. Stein
@ 1998-03-31 16:37 ` David Alan Gilbert
1998-03-31 22:05 ` Uncle George
1998-03-31 17:01 ` Michal Jaegermann
1998-03-31 17:10 ` Dominik Kubla
2 siblings, 1 reply; 7+ messages in thread
From: David Alan Gilbert @ 1998-03-31 16:37 UTC (permalink / raw)
To: axp-list
Harvey J. Stein wrote:
>
> I have an application which builds & runs fine on linux/alpha RH 4.2,
> but when I try to build & run it on linux/alpha RH 5.0 it fails. It
> seems to build fine, but when I run it I get an arithmetic trap reported
> by the kernel, and the program crashes with a floating point
> exception.
This seems to be fairly common; I whink -mieee on the compiler is supposed
to fix some of htem but I'm not sure.
Xaos 3.0 (Fractal zoomer) has the same problem on fractal types 2 & 3.
Dave
--
----------------------------------------------------------------------
- Dr. David Alan Gilbert - WARNING! This is a beta release .signature-
- Work: dg @ cogency.co.uk - 0161-428-9444 -
- Home: gro.gilbert @ treblig.org - -
----------------------------------------------------------------------
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: RH5.0 arithmetic traps.
1998-03-31 16:23 RH5.0 arithmetic traps Harvey J. Stein
1998-03-31 16:37 ` David Alan Gilbert
@ 1998-03-31 17:01 ` Michal Jaegermann
1998-03-31 21:56 ` Harvey J. Stein
1998-03-31 17:10 ` Dominik Kubla
2 siblings, 1 reply; 7+ messages in thread
From: Michal Jaegermann @ 1998-03-31 17:01 UTC (permalink / raw)
To: axp-list
>
>
> I have an application which builds & runs fine on linux/alpha RH 4.2,
> but when I try to build & run it on linux/alpha RH 5.0 it fails.
Try -mieee flag; this is a performance hit but handles exceptions
closer to what IEEE prescribes.
The fact that somethings run fine on something is not a proof for
an absence of bugs.
>
> Anyone have any ideas what might be wrong and/or how to fix it?
How about running gdb and checking? It is kind of hard to that
for you.
Michal
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: RH5.0 arithmetic traps.
1998-03-31 16:23 RH5.0 arithmetic traps Harvey J. Stein
1998-03-31 16:37 ` David Alan Gilbert
1998-03-31 17:01 ` Michal Jaegermann
@ 1998-03-31 17:10 ` Dominik Kubla
2 siblings, 0 replies; 7+ messages in thread
From: Dominik Kubla @ 1998-03-31 17:10 UTC (permalink / raw)
To: axp-list
Harvey Stein wrote:
> I have an application which builds & runs fine on linux/alpha RH 4.2,
> but when I try to build & run it on linux/alpha RH 5.0 it fails. It
> seems to build fine, but when I run it I get an arithmetic trap reported
> by the kernel, and the program crashes with a floating point
> exception.
>
> Anyone have any ideas what might be wrong and/or how to fix it?
Depends on what the application is doing: There were some problems im Linux and GLIBC
WRT to sqrt() and under/overflow. Richard Henderson submitted a patch for both which
appears to fix it, only one IEEE DEFECT is still reported by "paranoia" and i have already
submitted an informal bug-report. My last test was done with linux 2.1.91 and the glibc
snapshot from 03/15/98.
Dominik Kubla
--
Networking Group, University Hospital, Johannes Gutenberg-University
Obere Zahlbacher Straße 69, 55101 Mainz, Germany
Tel: +49 (0)6131 17-2482 FAX: +49 (0)6131 17-5521
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: RH5.0 arithmetic traps.
1998-03-31 17:01 ` Michal Jaegermann
@ 1998-03-31 21:56 ` Harvey J. Stein
1998-03-31 22:40 ` Uncle George
0 siblings, 1 reply; 7+ messages in thread
From: Harvey J. Stein @ 1998-03-31 21:56 UTC (permalink / raw)
To: axp-list; +Cc: hjstein
Michal Jaegermann <michal@ellpspace.math.ualberta.ca> writes:
> > I have an application which builds & runs fine on linux/alpha RH 4.2,
> > but when I try to build & run it on linux/alpha RH 5.0 it fails.
>
> Try -mieee flag; this is a performance hit but handles exceptions
> closer to what IEEE prescribes.
>
> The fact that somethings run fine on something is not a proof for
> an absence of bugs.
Yes ... but I don't see this on linux/intel RH 4.2, linux/alpha RH 4.2,
sun/sparc, and dg/ux.
> > Anyone have any ideas what might be wrong and/or how to fix it?
>
> How about running gdb and checking? It is kind of hard to that
> for you.
I tried to track it down in gdb, but got strange results. When I run
it straight through in GDB I get:
Program received signal SIGFPE, Arithmetic exception.
0x1200d58e0 in dfzerowexf_ () at dfzerowexf.f:285
Current language: auto; currently fortran
(gdb)
Above cited line is:
ER = 2.0D0 * D1MACH(4)
This is Fortran code (compiled with f2c). D1MACH is from the SLATEC
numerical library. D1MACH(4) is supposed to return 2^(-52).
If I break on the above line & step past, I don't get an arithmetic
exception.
--
Harvey J. Stein
Berger Financial Research
hjstein@bfr.co.il
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: RH5.0 arithmetic traps.
1998-03-31 16:37 ` David Alan Gilbert
@ 1998-03-31 22:05 ` Uncle George
0 siblings, 0 replies; 7+ messages in thread
From: Uncle George @ 1998-03-31 22:05 UTC (permalink / raw)
To: axp-list
yup,
gcc -mieee gives each float instruction a extra switch, which is
interperted by the kernel when the float execption occures. without it, the
kern merely reports the error to u. with it, the kernel tries to "fixup" the
error into something reasonable.
gat
BTW u pay for this services in more ways than the float exception the
occasionally occures.
David Alan Gilbert wrote:
> Harvey J. Stein wrote:
> >
> > I have an application which builds & runs fine on linux/alpha RH 4.2,
> > but when I try to build & run it on linux/alpha RH 5.0 it fails. It
> > seems to build fine, but when I run it I get an arithmetic trap reported
> > by the kernel, and the program crashes with a floating point
> > exception.
>
> This seems to be fairly common; I whink -mieee on the compiler is supposed
> to fix some of htem but I'm not sure.
>
> Xaos 3.0 (Fractal zoomer) has the same problem on fractal types 2 & 3.
>
> Dave
>
> --
> ----------------------------------------------------------------------
> - Dr. David Alan Gilbert - WARNING! This is a beta release .signature-
> - Work: dg @ cogency.co.uk - 0161-428-9444 -
> - Home: gro.gilbert @ treblig.org - -
> ----------------------------------------------------------------------
>
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: RH5.0 arithmetic traps.
1998-03-31 21:56 ` Harvey J. Stein
@ 1998-03-31 22:40 ` Uncle George
0 siblings, 0 replies; 7+ messages in thread
From: Uncle George @ 1998-03-31 22:40 UTC (permalink / raw)
To: axp-list; +Cc: hjstein
oh, fortran u say, the -mieee sa I stated was for C.
i suppose u do/do not know if d1mach(4) returns a nan/inf, or if ER is int ?
gat
BTW gdb & float operations are not all that reliable.
BTW#2 u can also breakpoint at the instruction itself
like :
b 0x1200d58e0
BUT u need to know what the assembler is so u also
need to do
disass dfzerowexf_
Harvey J. Stein wrote:
> Michal Jaegermann <michal@ellpspace.math.ualberta.ca> writes:
>
> > > I have an application which builds & runs fine on linux/alpha RH 4.2,
> > > but when I try to build & run it on linux/alpha RH 5.0 it fails.
> >
> > Try -mieee flag; this is a performance hit but handles exceptions
> > closer to what IEEE prescribes.
> >
> > The fact that somethings run fine on something is not a proof for
> > an absence of bugs.
>
> Yes ... but I don't see this on linux/intel RH 4.2, linux/alpha RH 4.2,
> sun/sparc, and dg/ux.
>
> > > Anyone have any ideas what might be wrong and/or how to fix it?
> >
> > How about running gdb and checking? It is kind of hard to that
> > for you.
>
> I tried to track it down in gdb, but got strange results. When I run
> it straight through in GDB I get:
>
> Program received signal SIGFPE, Arithmetic exception.
> 0x1200d58e0 in dfzerowexf_ () at dfzerowexf.f:285
> Current language: auto; currently fortran
> (gdb)
>
> Above cited line is:
>
> ER = 2.0D0 * D1MACH(4)
>
> This is Fortran code (compiled with f2c). D1MACH is from the SLATEC
> numerical library. D1MACH(4) is supposed to return 2^(-52).
>
> If I break on the above line & step past, I don't get an arithmetic
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~1998-03-31 22:37 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-03-31 16:23 RH5.0 arithmetic traps Harvey J. Stein
1998-03-31 16:37 ` David Alan Gilbert
1998-03-31 22:05 ` Uncle George
1998-03-31 17:01 ` Michal Jaegermann
1998-03-31 21:56 ` Harvey J. Stein
1998-03-31 22:40 ` Uncle George
1998-03-31 17:10 ` Dominik Kubla
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox