- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I've been chasing down a problem which so far has been reported only on one machine. The first solid evidence of something wrong is in the calculation of a double precision real COS value. On four machines I have, the calculation is correct. On the problem machine (which I don't have), the function returns incorrect values. Worse yet, it returns different values each time. I've had the user do a RAM test using the Microsoft test program, and it passes all tests. I'm of course suspicious of the problem machine, except for one thing -- an older version of my program which was compiled with the Compaq Fortran compiler runs fine. A test program which only calculates some cosine values functions perfectly on the problem machine when compiled with the Compaq compiler; it always produces incorrect values on the problem machine when compiled with the Intel compiler. (Both compilations do fine on my machines.)
Here's the test program:
Program CosExp
IMPLICIT NONE
REAL (KIND = 8) :: d, c
INTEGER (KIND = 4) :: i
open (UNIT=1, FILE='CosTest1c.txt', STATUS='replace')
write(1,*)'Value, Cos'
d = 1.558548156358005D-2
c = cos(d)
write(1,*),d,c
do i = 1, 20
d = .01D0 * i
c = cos(d)
write(1,*),d,c
end do
do i = 1, 20
d = .1D0 * i
c = cos(d)
write(1,*),d,c
end do
Close(1)
end
The first value to evaluate was chosen to be the same as a value in the program the user was having trouble with and where I first spotted the error. The test program was compiled with IVF v. 10.1.025 and CVF v. 6.6C. Default debug settings were used, which include no optimization. Here are the first few results when run on my machines -- both compilations produced identical results. The problem machine also produces identical results to these from the Compaq compiled program. These results are, as far as I can tell, correct.
Value, Cos
1.558548156358005E-002 0.999878548840693
1.000000000000000E-002 0.999950000416665
2.000000000000000E-002 0.999800006666578
3.000000000000000E-002 0.999550033748988
4.000000000000000E-002 0.999200106660978
5.000000000000000E-002 0.998750260394966
6.000000000000000E-002 0.998200539935204
7.000000000000001E-002 0.997551000253280
8.000000000000000E-002 0.996801706302619
9.000000000000000E-002 0.995952733011994
0.100000000000000 0.995004165278026
Here are the same calculations from the Intel compiled program run on the problem machine two different times:
Value, Cos
1.558548156358005E-002 0.999994306976907
1.000000000000000E-002 0.999999999999998
2.000000000000000E-002 0.999999999964238
3.000000000000000E-002 0.999999999678159
4.000000000000000E-002 0.999850019998933
5.000000000000000E-002 0.997590080547875
6.000000000000000E-002 0.997471971872478
7.000000000000001E-002 0.997154117664448
8.000000000000000E-002 0.996636549708941
9.000000000000000E-002 0.995919319762322
0.100000000000000 0.995002499546987
Value, Cos
1.558548156358005E-002 -1.221295362646600E+150
1.000000000000000E-002 0.999999999999998
2.000000000000000E-002 0.999999990845032
3.000000000000000E-002 0.999999999979885
4.000000000000000E-002 0.999999853535155
5.000000000000000E-002 0.997590080547875
6.000000000000000E-002 0.997471971872478
7.000000000000001E-002 0.997154117664448
8.000000000000000E-002 0.996636549708941
9.000000000000000E-002 0.995919319762322
0.100000000000000 0.995002499546987
Notice that E+150 result on the second run!
I tried explicitly calling DCOS instead of COS but the problem machine still produced bad results from the Intel compiled program.
The problem machine is a Dell Optiplex GX-260 with 2.8 GHz Pentium 4 processor, running Windows 2000 SP4. My test machines are a Pentium 4 running XP Pro, Pentium 3 running 2000 SP4, and Pentium 4 and Pentium 2 laptops running XP Pro. The Intel compiled program results are fine on all my machines. The user reports no problems with other applications, and no problems with an earlier version of my program compiled with the Compaq compiler. So there's something about the combination of the problem machine and the Intel compiler that's causing the errors. Any idea what it might be?
Link Copied
- « Previous
-
- 1
- 2
- Next »
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Like Linda's program, mine is being used on Windows systems including 98, ME, and 2000. The numbers are dwindling for these systems, of course, but the current total is probably on the order of a couple hundred. The Fortran portion is an .exe compiled as a Windows application and calls a number of Windows API functions but doesn't have any output that's visible to the user. No problems have been reported that I can blame on the Fortran program until the one under discussion, which I've positively identified on only one machine. And this problem is likely not due to the operating system, since I can't duplicate it here running Windows 2000 at the same revision level (SP4).
The bottom line, as I see it, is that at least some IVF-compiled programs, like Linda's and mine, can work fine on these systems, but Intel doesn't guarantee it. And you might run into a problem getting support if any failure happens on one of these systems which you can't duplicate on a supported system.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- « Previous
-
- 1
- 2
- Next »