JDK-6935535 : String.indexOf() returns incorrect result on x86 with SSE4.2
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: hs17,6u10,6u18,6u20
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS:
    linux,linux_redhat_4.0,solaris,solaris_2.5.1,solaris_10,windows_7 linux,linux_redhat_4.0,solaris,solaris_2.5.1,solaris_10,windows_7
  • CPU: x86
  • Submitted: 2010-03-17
  • Updated: 2010-09-24
  • Resolved: 2010-03-31
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7 Other
6u19-revFixed 7Fixed hs16.2Fixed
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Duplicate :  
Relates :  
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 http://hg.openjdk.java.net/hsx/hsx17/master/rev/13b5f241341a,ChangeRequest=6935535
26-03-2010

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

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