annotate test/compiler/uncommontrap/TraceDeoptimizationNoRealloc.java @ 21463:b1072d72fa2e

Lower checkcast arraycopy idiom after frame state assignment and convert arraycopy lowering into snippets
author Tom Rodriguez <tom.rodriguez@oracle.com>
date Thu, 21 May 2015 22:20:41 -0700
parents 793204f5528a
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
20706
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
1 /*
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
2 * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved.
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
4 *
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
5 * This code is free software; you can redistribute it and/or modify it
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
6 * under the terms of the GNU General Public License version 2 only, as
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
7 * published by the Free Software Foundation.
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
8 *
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
9 * This code is distributed in the hope that it will be useful, but WITHOUT
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
12 * version 2 for more details (a copy is included in the LICENSE file that
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
13 * accompanied this code).
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
14 *
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License version
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
16 * 2 along with this work; if not, write to the Free Software Foundation,
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
18 *
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
20 * or visit www.oracle.com if you need additional information or have any
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
21 * questions.
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
22 */
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
23
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
24 /*
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
25 * @test
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
26 * @bug 8067144
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
27 * @summary -XX:+TraceDeoptimization tries to print realloc'ed objects even when there are none
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
28 * @run main/othervm -XX:-BackgroundCompilation -XX:-UseOnStackReplacement -XX:+IgnoreUnrecognizedVMOptions -XX:+TraceDeoptimization TraceDeoptimizationNoRealloc
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
29 *
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
30 */
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
31
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
32 public class TraceDeoptimizationNoRealloc {
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
33
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
34 static void m(boolean some_condition) {
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
35 if (some_condition) {
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
36 return;
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
37 }
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
38 }
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
39
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
40
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
41 static public void main(String[] args) {
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
42 for (int i = 0; i < 20000; i++) {
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
43 m(false);
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
44 }
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
45 m(true);
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
46 }
793204f5528a 8067144: SIGSEGV with +TraceDeoptimization in Deoptimization::print_objects
roland
parents:
diff changeset
47 }