United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-5049410 Hotspot compiler changes behaviour of program
JDK-5049410 : Hotspot compiler changes behaviour of program

Details
Type:
Bug
Submit Date:
2004-05-19
Status:
Resolved
Updated Date:
2004-06-25
Project Name:
JDK
Resolved Date:
2004-06-15
Component:
hotspot
OS:
solaris_8
Sub-Component:
compiler
CPU:
sparc
Priority:
P2
Resolution:
Fixed
Affected Versions:
1.4.2_04
Fixed Versions:
1.4.2_06 (06)

Related Reports
Backport:

Sub Tasks

Description
The test case is as follows.

import cryptix.tools.UnixCrypt;

public class Test {
  public static void main(String args[]) {
     String cryptPass ="";
     String prePass = "";
     String account = "abcdefg";
     String password = "abcdefghi123";
     UnixCrypt jc = new UnixCrypt(account);
     for(int i = 0; i < 10000; i++)
     {
       cryptPass = jc.crypt(password);
       if(i != 0)
       {
           if(!prePass.equals(cryptPass))
           {
              System.out.println("Mismatch");
              break;
           }
        }
        prePass = cryptPass;
     }
  }
}

j2sdk1.4.2_04/bin/java -server -classpath .:cryptix32.jar Test

A mismatch is found when it shouldnt occur.  

The problem is not occuring when using 1.3.1_11 or 1.5.0-beta2-b49.
###@###.### 2004-05-18
###@###.### 2004-05-18

                                    

Comments
WORK AROUND

1. -Xcomp
2. -client
3. .hotspot_compiler with contents
exclude cryptix/tools/UnixCrypt crypt
###@###.### 2004-05-18
###@###.### 2004-05-18
                                     
2004-05-18
EVALUATION

What platform?  Hardware? OS? Thanks...
###@###.### 2004-05-19

Problem replicated in 1.5.0 Beta 2.

And Xor(arb, const) is mistakenly treated as
an  AddI(arb, const) by AddPNode::Ideal.

###@###.### 2004-05-28
                                     
2004-05-19
SUGGESTED FIX

http://analemma.sfbay.sun.com/net/prt-archiver.sfbay/export2/archived_workspaces/main/c2_baseline/2004/20040604095332.nips.xoraintadd/workspace/webrevs/webrev-2004.06.04/index.html
                                     
2004-07-08
CONVERTED DATA

BugTraq+ Release Management Values

COMMIT TO FIX:
1.4.2_06
generic
tiger-rc

FIXED IN:
1.4.2_06
tiger-rc

INTEGRATED IN:
1.4.2_06
tiger-b56
tiger-rc


                                     
2004-07-08



Hardware and Software, Engineered to Work Together