Wed, 27 Aug 2014 08:19:12 -0400
8046598: Scalable Native memory tracking development
Summary: Enhance scalability of native memory tracking
Reviewed-by: coleenp, ctornqvi, gtriantafill
kvn@1737 | 1 | /* |
trims@1907 | 2 | * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. |
kvn@1737 | 3 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
kvn@1737 | 4 | * |
kvn@1737 | 5 | * This code is free software; you can redistribute it and/or modify it |
kvn@1737 | 6 | * under the terms of the GNU General Public License version 2 only, as |
kvn@1737 | 7 | * published by the Free Software Foundation. |
kvn@1737 | 8 | * |
kvn@1737 | 9 | * This code is distributed in the hope that it will be useful, but WITHOUT |
kvn@1737 | 10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
kvn@1737 | 11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
kvn@1737 | 12 | * version 2 for more details (a copy is included in the LICENSE file that |
kvn@1737 | 13 | * accompanied this code). |
kvn@1737 | 14 | * |
kvn@1737 | 15 | * You should have received a copy of the GNU General Public License version |
kvn@1737 | 16 | * 2 along with this work; if not, write to the Free Software Foundation, |
kvn@1737 | 17 | * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
kvn@1737 | 18 | * |
trims@1907 | 19 | * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
trims@1907 | 20 | * or visit www.oracle.com if you need additional information or have any |
trims@1907 | 21 | * questions. |
kvn@1737 | 22 | */ |
kvn@1737 | 23 | |
kvn@1737 | 24 | /** |
kvn@1737 | 25 | * @test |
kvn@1737 | 26 | * @bug 6935535 |
kvn@1737 | 27 | * @summary String.indexOf() returns incorrect result on x86 with SSE4.2 |
kvn@1737 | 28 | * |
kvn@1737 | 29 | * @run main/othervm -Xcomp Test |
kvn@1737 | 30 | */ |
kvn@1737 | 31 | |
kvn@1737 | 32 | public class Test { |
kvn@1737 | 33 | |
kvn@1737 | 34 | static int IndexOfTest(String str) { |
kvn@1737 | 35 | return str.indexOf("1111111111111xx1x"); |
kvn@1737 | 36 | } |
kvn@1737 | 37 | |
kvn@1737 | 38 | public static void main(String args[]) { |
kvn@1737 | 39 | String str = "1111111111111xx1111111111111xx1x"; |
kvn@1737 | 40 | str = str.substring(0, 31); |
kvn@1737 | 41 | int idx = IndexOfTest(str); |
kvn@1737 | 42 | System.out.println("IndexOf(" + "1111111111111xx1x" + ") = " + idx + " in " + str); |
kvn@1737 | 43 | if (idx != -1) { |
kvn@1737 | 44 | System.exit(97); |
kvn@1737 | 45 | } |
kvn@1737 | 46 | } |
kvn@1737 | 47 | } |
kvn@1737 | 48 |