test/compiler/6896617/Test6896617.java
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File
*** old/test/compiler/6896617/Test6896617.java	Tue Oct 28 19:58:51 2014
--- new/test/compiler/6896617/Test6896617.java	Tue Oct 28 19:58:51 2014

*** 1,7 **** --- 1,7 ---- /* ! * Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation.
*** 23,39 **** --- 23,46 ---- /* * @test * @bug 6896617 * @summary Optimize sun.nio.cs.ISO_8859_1$Encode.encodeArrayLoop() with SSE instructions on x86 + * @library /testlibrary * @run main/othervm/timeout=1200 -Xbatch -Xmx256m Test6896617 * */ ! import java.util.*; ! import java.nio.*; ! import java.nio.charset.*; ! import com.oracle.java.testlibrary.Utils; ! import java.nio.ByteBuffer; ! import java.nio.CharBuffer; + import java.nio.charset.Charset; + import java.nio.charset.CharsetDecoder; + import java.nio.charset.CharsetEncoder; + import java.nio.charset.CodingErrorAction; + import java.util.Arrays; + import java.util.Random; public class Test6896617 { final static int SIZE = 256; public static void main(String[] args) {
*** 52,62 **** --- 59,69 ---- // Use internal API for tests. sun.nio.cs.ArrayEncoder arrenc = (sun.nio.cs.ArrayEncoder)enc; sun.nio.cs.ArrayDecoder arrdec = (sun.nio.cs.ArrayDecoder)dec; // Populate char[] with chars which can be encoded by ISO_8859_1 (<= 0xFF) ! Random rnd = new Random(0); ! Random rnd = Utils.getRandomInstance(); int maxchar = 0xFF; char[] a = new char[SIZE]; byte[] b = new byte[SIZE]; char[] at = new char[SIZE]; byte[] bt = new byte[SIZE];

test/compiler/6896617/Test6896617.java
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File