test/hotspot/jtreg/compiler/debug/TraceIterativeGVN.java
author rwestberg
Mon, 04 Jun 2018 16:21:08 +0200
changeset 50391 2bea53d7a27b
parent 47216 71c04702a3d5
child 51016 a926b7737d3b
permissions -rw-r--r--
8202095: JFR TestBiasedLockRevocationEvents should cope with multiple events during a single safepoint Reviewed-by: mgronlun, egahlin
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
27422
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     1
/*
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     2
 * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     4
 *
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    10
 *
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    15
 * accompanied this code).
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    16
 *
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    20
 *
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    23
 * questions.
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    24
 */
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    25
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    26
/*
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    27
 * @test
40059
c2304140ed64 8132919: Put compiler tests in packages
tpivovarova
parents: 27422
diff changeset
    28
 *
27422
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    29
 * @run main/othervm -Xbatch -XX:-TieredCompilation
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    30
 *                   -XX:+IgnoreUnrecognizedVMOptions -XX:+TraceIterativeGVN
40059
c2304140ed64 8132919: Put compiler tests in packages
tpivovarova
parents: 27422
diff changeset
    31
 *                   compiler.debug.TraceIterativeGVN
27422
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    32
 */
40059
c2304140ed64 8132919: Put compiler tests in packages
tpivovarova
parents: 27422
diff changeset
    33
c2304140ed64 8132919: Put compiler tests in packages
tpivovarova
parents: 27422
diff changeset
    34
package compiler.debug;
c2304140ed64 8132919: Put compiler tests in packages
tpivovarova
parents: 27422
diff changeset
    35
27422
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    36
public class TraceIterativeGVN {
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    37
    public static void main(String[] args) {
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    38
        for (int i = 0; i < 100_000; i++) {
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    39
            Byte.valueOf((byte)0);
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    40
        }
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    41
        System.out.println("TEST PASSED");
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    42
    }
954620f336dc 8036748: assert(_base == Int) failed: Not an Int w/ -XX:+TraceIterativeGVN
vlivanov
parents:
diff changeset
    43
}