-
Bug
-
Resolution: Fixed
-
P1
-
1.3.1
-
ladybird
-
x86
-
solaris_8
-
Verified
HotSpot Client build 1.3.1ea-b01 in compiled (-Xcomp) mode (Solaris-x86) treats double values incorectly.
This bug can be reproduced by the simplest test.
Test source, script to run and log follow:
-------------------------- test86.java -----------------------------
public class test86 {
public static void main (String argv[]) {
double d1=0.1;
double d2=0.2;
System.out.println("d1 = " + d1);
System.out.println("d2 = " + d2);
}
}
---------------------------test86.sh----------------------------
#!/bin/sh
HSJDK=/usr/local/java/jdk1.3.1/solx86
JAVA=${HSJDK}/bin/java
JAVAC=${HSJDK}/bin/javac
$JAVAC test86.java
echo =======
$JAVA -version
$JAVA test86
echo =======
$JAVA -Xcomp -version
$JAVA -Xcomp test86
echo =======
------------------------------log------------------------------
% uname -a
SunOS corellia 5.8 Generic i86pc i386 i86pc
%test86.sh
=======
java version "1.3.1ea"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1ea-b01)
Java HotSpot(TM) Client VM (build 1.3.1ea-b01, mixed mode)
d1 = 0.1
d2 = 0.2
=======
java version "1.3.1ea"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1ea-b01)
Java HotSpot(TM) Client VM (build 1.3.1ea-b01, compiled mode)
d1 = -3.305620293539215E150
d2 = -3.3056202996363804E150
=======
This bug can be reproduced by the simplest test.
Test source, script to run and log follow:
-------------------------- test86.java -----------------------------
public class test86 {
public static void main (String argv[]) {
double d1=0.1;
double d2=0.2;
System.out.println("d1 = " + d1);
System.out.println("d2 = " + d2);
}
}
---------------------------test86.sh----------------------------
#!/bin/sh
HSJDK=/usr/local/java/jdk1.3.1/solx86
JAVA=${HSJDK}/bin/java
JAVAC=${HSJDK}/bin/javac
$JAVAC test86.java
echo =======
$JAVA -version
$JAVA test86
echo =======
$JAVA -Xcomp -version
$JAVA -Xcomp test86
echo =======
------------------------------log------------------------------
% uname -a
SunOS corellia 5.8 Generic i86pc i386 i86pc
%test86.sh
=======
java version "1.3.1ea"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1ea-b01)
Java HotSpot(TM) Client VM (build 1.3.1ea-b01, mixed mode)
d1 = 0.1
d2 = 0.2
=======
java version "1.3.1ea"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1ea-b01)
Java HotSpot(TM) Client VM (build 1.3.1ea-b01, compiled mode)
d1 = -3.305620293539215E150
d2 = -3.3056202996363804E150
=======
- relates to
-
JDK-4379537 HS1.4(x86 -Xcomp) treats double values incorectly
- Closed
-
JDK-4379471 HS Client (-Xcomp, solaris-x86) treats double values incorrectly
- Closed