United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6935535 String.indexOf() returns incorrect result on x86 with SSE4.2
JDK-6935535 : String.indexOf() returns incorrect result on x86 with SSE4.2

Details
Type:
Bug
Submit Date:
2010-03-17
Status:
Resolved
Updated Date:
2010-09-24
Project Name:
JDK
Resolved Date:
2010-03-31
Component:
hotspot
OS:
solaris,linux_redhat_4.0,solaris_2.5.1,linux,solaris_10,windows_7
Sub-Component:
compiler
CPU:
x86
Priority:
P4
Resolution:
Fixed
Affected Versions:
hs17,6u10,6u18,6u20
Fixed Versions:
hs17 (b12)

Related Reports
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:
Backport:
Duplicate:
Duplicate:
Duplicate:
Duplicate:
Relates:

Sub Tasks

Description
% java -Xcomp Test
IndexOf(1111111111111xx1x) = 15 in 1111111111111xx1111111111111xx1

% cat Test.java
public class Test {

  static int IndexOfTest(String str) {
    return str.indexOf("1111111111111xx1x");
  }

  public static void main(String args[]) {
    String str = "1111111111111xx1111111111111xx1x";
    str = str.substring(0, 31);
    int idx = IndexOfTest(str);
    System.out.println("IndexOf(" + "1111111111111xx1x" + ") = " + idx + " in " + str);
  }
}

                                    

Comments
EVALUATION

ChangeSet=http://hg.openjdk.java.net/jdk7/hotspot-comp/hotspot/rev/2484f4d6a54e,ChangeRequest=6935535
                                     
2010-03-17
EVALUATION

ChangeSet=http://hg.openjdk.java.net/hsx/hsx17/baseline/rev/13b5f241341a,ChangeRequest=6935535
                                     
2010-03-19
EVALUATION

http://hg.openjdk.java.net/hsx/hsx17/master/rev/13b5f241341a,ChangeRequest=6935535
                                     
2010-03-26



Hardware and Software, Engineered to Work Together