Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* Re: g77 problems
@ 1998-09-02  1:27 Greg Lindahl
  0 siblings, 0 replies; 15+ messages in thread
From: Greg Lindahl @ 1998-09-02  1:27 UTC (permalink / raw)
  To: axp-list

> My FORTRAN program works fine using fort77 but fails due to
> Floating Exception when I use  g77 compiler.  I have been debugging
> this  program and when I insert  a write(*,*) statement
> in one of the subroutines the programs executes fine. I used
> xxgdb to debug the program and it showed problem in cosine  function
> (libm).

A floating point exception that comes and goes when you insert a
write(*,*) is usually a sign of an incorrect program. Different
compilers will then give different answers. Try turning on bounds
checking in fort77, etc, to try to find your bug. If you are
overwriting memory, writing an integer value into a floating point
variable sometimes produces a denormalized number, which results in
a crash on the alpha.

On the other hand, you may be really generating a denorm. In that
case compiling with g77 -mieee may be the fix. But in that case fort77
should also be showing a floating exception.

-- g


^ permalink raw reply	[flat|nested] 15+ messages in thread
* Re: g77 problems
@ 1998-09-03 21:08 Greg Lindahl
  0 siblings, 0 replies; 15+ messages in thread
From: Greg Lindahl @ 1998-09-03 21:08 UTC (permalink / raw)
  To: axp-list

> Underflows are set to zero according to the architecture
> stuff I read.

However, if you're reading garbage memory, you might get a denorm.
This is what we were suggesting in this case.

> If a number cannot be represented normalized, you're in
> trouble because IEEE FP format has an implied 1 bit in the
> mantissa.

If a number can't be normalized, it is expressed by a denorm, which
does not have an implied 1 bit. The alpha neither generates nor
consumes denorms unless you specify the -mieee flag and pay a big
penalty.

-- g


^ permalink raw reply	[flat|nested] 15+ messages in thread
* g77 problems
@ 1998-09-01 10:56 Dr P. Caleb Dhanasekaran
  1998-09-02  1:48 ` Michal Jaegermann
  1998-09-02  4:23 ` Wes Bauske
  0 siblings, 2 replies; 15+ messages in thread
From: Dr P. Caleb Dhanasekaran @ 1998-09-01 10:56 UTC (permalink / raw)
  To: axp-list; +Cc: Caleb Dhanasekaran


Hi all`,

I have installed RedHat 5.1 on my Alpha  UX4,600Mhz PC. I have
upgraded the compilers egcs.1.0.3 and g77-1.0.3 downloading the
rpm files.

My FORTRAN program works fine using fort77 but fails due to
Floating Exception when I use  g77 compiler.  I have been debugging
this  program and when I insert  a write(*,*) statement
in one of the subroutines the programs executes fine. I used
xxgdb to debug the program and it showed problem in cosine  function
(libm).

Could anybody tell me what causes this type of Floating Exception
problem using g77 on Alpha?  Is there any fix to this? This program works
fine on IBM Aix 4.1, HP, Silcon Graphics systems, and g77 on Intel
platform.`

Thanks,
Caleb



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

end of thread, other threads:[~1998-09-06 22:41 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-09-02  1:27 g77 problems Greg Lindahl
  -- strict thread matches above, loose matches on Subject: below --
1998-09-03 21:08 Greg Lindahl
1998-09-01 10:56 Dr P. Caleb Dhanasekaran
1998-09-02  1:48 ` Michal Jaegermann
1998-09-02  4:23 ` Wes Bauske
1998-09-02 15:34   ` David Alan Gilbert
1998-09-03  6:23     ` Wes Bauske
1998-09-04  0:41       ` Richard Henderson
1998-09-05 19:57         ` Wes Bauske
1998-09-05 20:50           ` Richard Henderson
1998-09-06 20:22             ` Dave Gilbert
1998-09-06 21:05               ` Wes Bauske
1998-09-06 22:41               ` Richard Henderson
1998-09-06 20:28             ` Richard Hadsell
1998-09-06 20:57               ` Wes Bauske

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox