[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: g77 issues

Ionut Georgescu wrote:

> PS command line: g77 -g -pg -o programm *.f
> PPS gcc -v:
>     Reading specs from /usr/lib/gcc-lib/alpha-linux/2.95.3/specs
>     gcc version 2.95.3 20010315 (Debian release)

I'm interested... I don't know enough FORTRAN to test this out, but I have been
seeing Scilab (which has a lot of FORTRAN inside) doing some strange things
recently.  If you were to send me a short program to compile and run on this
debian PowerPC (Mac G4) I can let you see the results.

> PPS I made another test. In the big programm I have defined a function
> fermi2:
> ...
> and computed the following expression:
>           aux22= 1.0d0-fermi2(enpct)
> The output was:
> on x86:
>  tmp_fermi2( -2.20214243)=  1.
>  aux22=  1.11022302E-16  !! should have been 0. !!

This is an engineering department: 1.11022302E-16 == 0  ;-)  Can you print out
the first expression more accuately?  I bet it isn't really 1 (actually
1.000000000000000111022302 ;-)  Maybe there's no bug: it's just truncation
error?  Maybe the maths unit on the alpha is better than the one on the ia32 on
this test (no suprise there!)

> on alpha:
>  tmp_fermi2( -2.20214243)=  1.
>  aux22=  0.

I notice this is quite cross-posted: maybe we should reduce the lists it's sent
to?  Apologies to people receiving this from someone not on their list (better
cc replies to me if you want me to read them)


tel;cell:+44 7980 817634
tel;work:+44 141 330 4902
org:University of Glasgow;Centre for Music Technology
title:Senior Lecturer and Co-director
fn:Nicholas Bailey

Reply to: