9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /**
25 * @test
26 * @bug 8073583
27 * @summary C2 support for CRC32C on SPARC
28 *
29 * @run main/othervm/timeout=600 -Xbatch TestCRC32C -m
30 */
31
32 import java.nio.ByteBuffer;
33 import java.util.zip.Checksum;
34 import java.util.zip.CRC32C;
35
36 public class TestCRC32C {
37 public static void main(String[] args) {
38 int offset = Integer.getInteger("offset", 0);
39 int msgSize = Integer.getInteger("msgSize", 512);
40 boolean multi = false;
41 int iters = 20000;
42 int warmupIters = 20000;
43
44 if (args.length > 0) {
45 if (args[0].equals("-m")) {
46 multi = true;
47 } else {
48 iters = Integer.valueOf(args[0]);
49 }
50 if (args.length > 1) {
51 warmupIters = Integer.valueOf(args[1]);
52 }
53 }
54
|
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /**
25 * @test
26 * @bug 8073583
27 * @summary C2 support for CRC32C on SPARC
28 *
29 * @run main/othervm/timeout=600 -Xbatch compiler.intrinsics.zip.TestCRC32C -m
30 */
31
32 package compiler.intrinsics.zip;
33
34 import java.nio.ByteBuffer;
35 import java.util.zip.CRC32C;
36 import java.util.zip.Checksum;
37
38 public class TestCRC32C {
39 public static void main(String[] args) {
40 int offset = Integer.getInteger("offset", 0);
41 int msgSize = Integer.getInteger("msgSize", 512);
42 boolean multi = false;
43 int iters = 20000;
44 int warmupIters = 20000;
45
46 if (args.length > 0) {
47 if (args[0].equals("-m")) {
48 multi = true;
49 } else {
50 iters = Integer.valueOf(args[0]);
51 }
52 if (args.length > 1) {
53 warmupIters = Integer.valueOf(args[1]);
54 }
55 }
56
|