Compaq Visual Fortran on WINDOWS Problem
From: Eric Mcintosh (Eric.Mcintosh_at_cern.ch)
Date: 05/25/04
- Next message: Jan Vorbrüggen: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Previous message: Jan Vorbrüggen: "Re: long free source form lines"
- Next in thread: Jan Vorbrüggen: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Reply: Jan Vorbrüggen: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Reply: Eric Mcintosh: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Reply: Richard Maine: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 25 May 2004 12:48:58 +0200
I am using the ex-Compaq Visual Fortran 6.1A compiler on
Windows 2000 and Windows XP systems at CERN.
(This has been our default compiler for Windows for many years.)
After laborious research I identified the following problem
and produced the test program.
program mynum
implicit none
double precision extaux,con
integer mycon(2),myextaux(2)
equivalence (extaux,myextaux(1))
equivalence (con,mycon(1))
con=-3.756403155274550d-09
write (*,'(a20,f47.33)') ' CON ',con
write (*,'(a20,2z8)') ' HEX ',mycon(2),mycon(1)
open(20,file='extaux',form='formatted')
read (20,*) extaux
write (*,'(a20,f47.33)') ' EXTAUX ',extaux
write (*,'(a20,2z8)') ' HEX ',myextaux(2),myextaux(1)
end
The data file fort.20 contains
6.578151765187548e-10 -4.769934558813349e-09 9.080361228508333e-09
1.761146505216348e-08 -3.756403155274550e-09 0.000000000000000e+00
The correct ouput is
CON -0.000000003756403155274549586578007
HEX BE3022357D9B0650
extaux31 -0.000000003756403155274549586578007
HEX BE3022357D9B0650
but on Windows 2000 I get
CON -0.000000003756403155274549586578007
HEX BE3022357D9B0650
extaux31 -0.000000003756403155274550413758619
HEX BE3022357D9B0651
On Linux, where I have several Fortran compilers available, and especially
NAG f95 5.0, I have no problem whatsoever.
On Windows XP with my Compaq Fortran, no problem either. On Windows 2000
however, the 5th number read in is 1 bit too big. I have switched
compilers on Windows to use Lahey-Fujitsu lf95 6.1 and now all is well
again.
I have been told "it only happens with old compilers"! The same person
reported
the same error with an old Intel compiler on Windows XP!!!
I have just run 15,000 rather important jobs on Windows using 600
input files. 505 of my 600 files are treated wrongly on Windows 2000 with
from
1 to 7 errors in each file, always one bit too big.
NOTA BENE. It is essential to read the 6 numbers as given for the 5th number
to be wrong.
Just reading the last three numbers or the number itself is OK.
It seems to me I have a strange problem that is both compiler and OS
dependent. Any information
about this would be extremely welcome. I am studying chaotic behaviour and
this seemingly tiny
error grows exponentially in my model.
Regards and thanks for any information. Eric.
Eric McIntosh, IT/PS, G07510, CERN, CH-1211 GENEVA 23.
+41 22 767 49 34 (Office with answering machine).
+41 22 767 71 55 (FAX office, weekdays only).
+41 76 487 40 50 (Portable, often on silent)
- Next message: Jan Vorbrüggen: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Previous message: Jan Vorbrüggen: "Re: long free source form lines"
- Next in thread: Jan Vorbrüggen: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Reply: Jan Vorbrüggen: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Reply: Eric Mcintosh: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Reply: Richard Maine: "Re: Compaq Visual Fortran on WINDOWS Problem"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|