Mercurial > hg > graal-jvmci-8
annotate src/share/vm/jvmci/jvmciRuntime.hpp @ 23779:16b5e00d9196
renamed JVMCIPrintFlags to JVMCIPrintSystemProperties
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Wed, 05 Oct 2016 13:58:15 +0200 |
parents | b1b5c71c04b7 |
children |
rev | line source |
---|---|
5526
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
1 /* |
23319
c1935b089c01
8151470: [JVMCI] remove up-call to HotSpotJVMCICompilerConfig.selectCompiler
Roland Schatz <roland.schatz@oracle.com>
parents:
22761
diff
changeset
|
2 * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved. |
5526
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
4 * |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
5 * This code is free software; you can redistribute it and/or modify it |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
6 * under the terms of the GNU General Public License version 2 only, as |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
7 * published by the Free Software Foundation. |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
8 * |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
9 * This code is distributed in the hope that it will be useful, but WITHOUT |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
12 * version 2 for more details (a copy is included in the LICENSE file that |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
13 * accompanied this code). |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
14 * |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
15 * You should have received a copy of the GNU General Public License version |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
16 * 2 along with this work; if not, write to the Free Software Foundation, |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
18 * |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
20 * or visit www.oracle.com if you need additional information or have any |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
21 * questions. |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
22 */ |
87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff
changeset
|
23 |
21559
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
24 #ifndef SHARE_VM_JVMCI_JVMCI_RUNTIME_HPP |
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
25 #define SHARE_VM_JVMCI_JVMCI_RUNTIME_HPP |
5747
120820e30baa
added basic high-level interpreter support to HotSpot
Christian Haeubl <haeubl@ssw.jku.at>
parents:
5526
diff
changeset
|
26 |
7125
1baf7f1e3f23
decoupled C++ Graal runtime from C1
Doug Simon <doug.simon@oracle.com>
parents:
6559
diff
changeset
|
27 #include "interpreter/interpreter.hpp" |
1baf7f1e3f23
decoupled C++ Graal runtime from C1
Doug Simon <doug.simon@oracle.com>
parents:
6559
diff
changeset
|
28 #include "memory/allocation.hpp" |
21956
35affb9c707a
add properties from <jdk>/jre/lib/jvmci/*.properties files to system properties
Doug Simon <doug.simon@oracle.com>
parents:
21875
diff
changeset
|
29 #include "runtime/arguments.hpp" |
7125
1baf7f1e3f23
decoupled C++ Graal runtime from C1
Doug Simon <doug.simon@oracle.com>
parents:
6559
diff
changeset
|
30 #include "runtime/deoptimization.hpp" |
1baf7f1e3f23
decoupled C++ Graal runtime from C1
Doug Simon <doug.simon@oracle.com>
parents:
6559
diff
changeset
|
31 |
22722
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
32 #define JVMCI_ERROR(...) \ |
23392
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
33 { JVMCIRuntime::fthrow_error(THREAD_AND_LOCATION, __VA_ARGS__); return; } |
22722
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
34 |
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
35 #define JVMCI_ERROR_(ret, ...) \ |
23392
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
36 { JVMCIRuntime::fthrow_error(THREAD_AND_LOCATION, __VA_ARGS__); return ret; } |
22722
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
37 |
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
38 #define JVMCI_ERROR_0(...) JVMCI_ERROR_(0, __VA_ARGS__) |
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
39 #define JVMCI_ERROR_NULL(...) JVMCI_ERROR_(NULL, __VA_ARGS__) |
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
40 #define JVMCI_ERROR_OK(...) JVMCI_ERROR_(JVMCIEnv::ok, __VA_ARGS__) |
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
41 #define CHECK_OK CHECK_(JVMCIEnv::ok) |
0229a2ca608b
Make kindToBasicType trapping.
Roland Schatz <roland.schatz@oracle.com>
parents:
22685
diff
changeset
|
42 |
22454
76af33d4d504
Make jvmci redefinition safe
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22429
diff
changeset
|
43 class JVMCIRuntime: public AllStatic { |
23379
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
44 public: |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
45 // Constants describing whether JVMCI wants to be able to adjust the compilation |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
46 // level selected for a method by the VM compilation policy and if so, based on |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
47 // what information about the method being schedule for compilation. |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
48 enum CompLevelAdjustment { |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
49 none = 0, // no adjustment |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
50 by_holder = 1, // adjust based on declaring class of method |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
51 by_full_signature = 2 // adjust based on declaring class, name and signature of method |
23408
f84a5ac3be22
make JVMCI JDK immutable and sharable among different JVMCI clients
Doug Simon <doug.simon@oracle.com>
parents:
23392
diff
changeset
|
52 }; |
23379
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
53 |
15582
063ec2920d21
made Graal runtime initialization in hosted mode lazy
Doug Simon <doug.simon@oracle.com>
parents:
14731
diff
changeset
|
54 private: |
21527
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
55 static jobject _HotSpotJVMCIRuntime_instance; |
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
56 static bool _HotSpotJVMCIRuntime_initialized; |
15870
fe608a56e3f7
made HotSpotOptions processing faster by removing use of service loader in VM startup and only doing work for options specified on the command line
Doug Simon <doug.simon@oracle.com>
parents:
15603
diff
changeset
|
57 |
22575
569c82ebb96e
Replace JVMCICompileWithC1Only with package based controls
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22574
diff
changeset
|
58 static int _trivial_prefixes_count; |
569c82ebb96e
Replace JVMCICompileWithC1Only with package based controls
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22574
diff
changeset
|
59 static char** _trivial_prefixes; |
569c82ebb96e
Replace JVMCICompileWithC1Only with package based controls
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22574
diff
changeset
|
60 |
23379
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
61 static CompLevelAdjustment _comp_level_adjustment; |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
62 |
18303
ab47ef2f2207
disable blocking compilation requests once GraalRuntime::shutdown has been called
Doug Simon <doug.simon@oracle.com>
parents:
18227
diff
changeset
|
63 static bool _shutdown_called; |
ab47ef2f2207
disable blocking compilation requests once GraalRuntime::shutdown has been called
Doug Simon <doug.simon@oracle.com>
parents:
18227
diff
changeset
|
64 |
23379
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
65 static CompLevel adjust_comp_level_inner(methodHandle method, bool is_osr, CompLevel level, JavaThread* thread); |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
66 |
7125
1baf7f1e3f23
decoupled C++ Graal runtime from C1
Doug Simon <doug.simon@oracle.com>
parents:
6559
diff
changeset
|
67 public: |
23327
19c85f6618ed
re-add support for parsing jre/jvmci/*.properties files
Doug Simon <doug.simon@oracle.com>
parents:
23323
diff
changeset
|
68 |
19c85f6618ed
re-add support for parsing jre/jvmci/*.properties files
Doug Simon <doug.simon@oracle.com>
parents:
23323
diff
changeset
|
69 /** |
21559
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
70 * Ensures that the JVMCI class loader is initialized and the well known JVMCI classes are loaded. |
18614
c307546c7b0a
made initialization of the Graal class loader and well known Graal classes lazy
Doug Simon <doug.simon@oracle.com>
parents:
18303
diff
changeset
|
71 */ |
21559
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
72 static void ensure_jvmci_class_loader_is_initialized(); |
18614
c307546c7b0a
made initialization of the Graal class loader and well known Graal classes lazy
Doug Simon <doug.simon@oracle.com>
parents:
18303
diff
changeset
|
73 |
23319
c1935b089c01
8151470: [JVMCI] remove up-call to HotSpotJVMCICompilerConfig.selectCompiler
Roland Schatz <roland.schatz@oracle.com>
parents:
22761
diff
changeset
|
74 static bool is_HotSpotJVMCIRuntime_initialized() { |
c1935b089c01
8151470: [JVMCI] remove up-call to HotSpotJVMCICompilerConfig.selectCompiler
Roland Schatz <roland.schatz@oracle.com>
parents:
22761
diff
changeset
|
75 return _HotSpotJVMCIRuntime_initialized; |
c1935b089c01
8151470: [JVMCI] remove up-call to HotSpotJVMCICompilerConfig.selectCompiler
Roland Schatz <roland.schatz@oracle.com>
parents:
22761
diff
changeset
|
76 } |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
77 |
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
78 /** |
21527
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
79 * Gets the singleton HotSpotJVMCIRuntime instance, initializing it if necessary |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
80 */ |
22574
5a706439be63
Propagate exceptions up instead of aborting
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22544
diff
changeset
|
81 static Handle get_HotSpotJVMCIRuntime(TRAPS) { |
5a706439be63
Propagate exceptions up instead of aborting
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22544
diff
changeset
|
82 initialize_JVMCI(CHECK_(Handle())); |
21527
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
83 return Handle(JNIHandles::resolve_non_null(_HotSpotJVMCIRuntime_instance)); |
19920
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
84 } |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
85 |
22574
5a706439be63
Propagate exceptions up instead of aborting
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22544
diff
changeset
|
86 static jobject get_HotSpotJVMCIRuntime_jobject(TRAPS) { |
5a706439be63
Propagate exceptions up instead of aborting
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22544
diff
changeset
|
87 initialize_JVMCI(CHECK_NULL); |
21527
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
88 assert(_HotSpotJVMCIRuntime_initialized, "must be"); |
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
89 return _HotSpotJVMCIRuntime_instance; |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
90 } |
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
91 |
22574
5a706439be63
Propagate exceptions up instead of aborting
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22544
diff
changeset
|
92 static Handle callStatic(const char* className, const char* methodName, const char* returnType, JavaCallArguments* args, TRAPS); |
19920
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
93 |
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
94 /** |
21527
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
95 * Trigger initialization of HotSpotJVMCIRuntime through JVMCI.getRuntime() |
19920
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
96 */ |
22574
5a706439be63
Propagate exceptions up instead of aborting
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22544
diff
changeset
|
97 static void initialize_JVMCI(TRAPS); |
19920
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
98 |
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
99 /** |
21527
07b088d61d5d
added HotSpotJVMCIRuntime* classes, replaced references to HotSpotGraalRuntime in VM with HotSpotJVMCIRuntime (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21473
diff
changeset
|
100 * Explicitly initialize HotSpotJVMCIRuntime itself |
19920
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
101 */ |
22574
5a706439be63
Propagate exceptions up instead of aborting
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22544
diff
changeset
|
102 static void initialize_HotSpotJVMCIRuntime(TRAPS); |
19920
7366593c0610
Make the native initialization path for Graal more robust
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
19009
diff
changeset
|
103 |
22454
76af33d4d504
Make jvmci redefinition safe
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22429
diff
changeset
|
104 static void metadata_do(void f(Metadata*)); |
76af33d4d504
Make jvmci redefinition safe
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22429
diff
changeset
|
105 |
23408
f84a5ac3be22
make JVMCI JDK immutable and sharable among different JVMCI clients
Doug Simon <doug.simon@oracle.com>
parents:
23392
diff
changeset
|
106 static void shutdown(TRAPS); |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
107 |
23385 | 108 static void bootstrap_finished(TRAPS); |
23383
0226d6bcb0d2
Notify the compiler on completion of a bootstrap (JDK-8156034)
Josef Eisl <josef.eisl@jku.at>
parents:
23379
diff
changeset
|
109 |
18303
ab47ef2f2207
disable blocking compilation requests once GraalRuntime::shutdown has been called
Doug Simon <doug.simon@oracle.com>
parents:
18227
diff
changeset
|
110 static bool shutdown_called() { |
ab47ef2f2207
disable blocking compilation requests once GraalRuntime::shutdown has been called
Doug Simon <doug.simon@oracle.com>
parents:
18227
diff
changeset
|
111 return _shutdown_called; |
ab47ef2f2207
disable blocking compilation requests once GraalRuntime::shutdown has been called
Doug Simon <doug.simon@oracle.com>
parents:
18227
diff
changeset
|
112 } |
ab47ef2f2207
disable blocking compilation requests once GraalRuntime::shutdown has been called
Doug Simon <doug.simon@oracle.com>
parents:
18227
diff
changeset
|
113 |
22575
569c82ebb96e
Replace JVMCICompileWithC1Only with package based controls
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22574
diff
changeset
|
114 static bool treat_as_trivial(Method* method); |
569c82ebb96e
Replace JVMCICompileWithC1Only with package based controls
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22574
diff
changeset
|
115 |
15941
b35b1dc75ec0
added comments to explain the origin of generated sources
Doug Simon <doug.simon@oracle.com>
parents:
15916
diff
changeset
|
116 /** |
23379
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
117 * Lets JVMCI modify the compilation level currently selected for a method by |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
118 * the VM compilation policy. |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
119 * |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
120 * @param method the method being scheduled for compilation |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
121 * @param is_osr specifies if the compilation is an OSR compilation |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
122 * @param level the compilation level currently selected by the VM compilation policy |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
123 * @param thread the current thread |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
124 * @return the compilation level to use for the compilation |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
125 */ |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
126 static CompLevel adjust_comp_level(methodHandle method, bool is_osr, CompLevel level, JavaThread* thread); |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
127 |
24505bf61633
allow JVMCI compiler to change the compilation policy for a method (JDK-8152311)
Doug Simon <doug.simon@oracle.com>
parents:
23367
diff
changeset
|
128 /** |
23392
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
129 * Throws a JVMCIError with a formatted error message. Ideally we would use |
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
130 * a variation of Exceptions::fthrow that takes a class loader argument but alas, |
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
131 * no such variation exists. |
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
132 */ |
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
133 static void fthrow_error(Thread* thread, const char* file, int line, const char* format, ...) ATTRIBUTE_PRINTF(4, 5); |
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
134 |
b3a816d3b844
Backed out changeset: a920338dd4d4
Doug Simon <doug.simon@oracle.com>
parents:
23387
diff
changeset
|
135 /** |
23751
b1b5c71c04b7
replace use of vm_abort with vm_exit
Doug Simon <doug.simon@oracle.com>
parents:
23709
diff
changeset
|
136 * Exits the VM due to an unexpected exception. |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
137 */ |
23751
b1b5c71c04b7
replace use of vm_abort with vm_exit
Doug Simon <doug.simon@oracle.com>
parents:
23709
diff
changeset
|
138 static void exit_on_pending_exception(Handle exception, const char* message); |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
139 |
23751
b1b5c71c04b7
replace use of vm_abort with vm_exit
Doug Simon <doug.simon@oracle.com>
parents:
23709
diff
changeset
|
140 #define CHECK_EXIT THREAD); \ |
16428
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
141 if (HAS_PENDING_EXCEPTION) { \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
142 char buf[256]; \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
143 jio_snprintf(buf, 256, "Uncaught exception at %s:%d", __FILE__, __LINE__); \ |
23751
b1b5c71c04b7
replace use of vm_abort with vm_exit
Doug Simon <doug.simon@oracle.com>
parents:
23709
diff
changeset
|
144 JVMCIRuntime::exit_on_pending_exception(PENDING_EXCEPTION, buf); \ |
16428
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
145 return; \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
146 } \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
147 (void)(0 |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
148 |
23751
b1b5c71c04b7
replace use of vm_abort with vm_exit
Doug Simon <doug.simon@oracle.com>
parents:
23709
diff
changeset
|
149 #define CHECK_EXIT_(result) THREAD); \ |
16428
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
150 if (HAS_PENDING_EXCEPTION) { \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
151 char buf[256]; \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
152 jio_snprintf(buf, 256, "Uncaught exception at %s:%d", __FILE__, __LINE__); \ |
23751
b1b5c71c04b7
replace use of vm_abort with vm_exit
Doug Simon <doug.simon@oracle.com>
parents:
23709
diff
changeset
|
153 JVMCIRuntime::exit_on_pending_exception(PENDING_EXCEPTION, buf); \ |
16428
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
154 return result; \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
155 } \ |
78ddecd6255f
added CHECK macros in uses of SymbolTable::new_symbol; added CHECK_ABORT macros for TRAPS functions that must abort the VM if they throw an exception
Doug Simon <doug.simon@oracle.com>
parents:
16395
diff
changeset
|
156 (void)(0 |
16006
66a9286203a2
decoupled Graal runtime initialization and Graal compilation queue initialization
Doug Simon <doug.simon@oracle.com>
parents:
15941
diff
changeset
|
157 |
16395
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
158 /** |
21559
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
159 * Same as SystemDictionary::resolve_or_null but uses the JVMCI loader. |
16395
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
160 */ |
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
161 static Klass* resolve_or_null(Symbol* name, TRAPS); |
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
162 |
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
163 /** |
21559
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
164 * Same as SystemDictionary::resolve_or_fail but uses the JVMCI loader. |
16395
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
165 */ |
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
166 static Klass* resolve_or_fail(Symbol* name, TRAPS); |
ad431bf0de07
added support to load classes from graal.jar with a separate class loader
Doug Simon <doug.simon@oracle.com>
parents:
16273
diff
changeset
|
167 |
23408
f84a5ac3be22
make JVMCI JDK immutable and sharable among different JVMCI clients
Doug Simon <doug.simon@oracle.com>
parents:
23392
diff
changeset
|
168 static BasicType kindToBasicType(Handle kind, TRAPS); |
15582
063ec2920d21
made Graal runtime initialization in hosted mode lazy
Doug Simon <doug.simon@oracle.com>
parents:
14731
diff
changeset
|
169 |
21559
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
170 // The following routines are all called from compiled JVMCI code |
15582
063ec2920d21
made Graal runtime initialization in hosted mode lazy
Doug Simon <doug.simon@oracle.com>
parents:
14731
diff
changeset
|
171 |
9352
d4684b468e93
made NewInstanceStub a RuntimeStub that directly calls the C runtime (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9338
diff
changeset
|
172 static void new_instance(JavaThread* thread, Klass* klass); |
9338
0266549ff6e0
added support from compiled stubs to be installed as RuntimeStubs and to be able to directly call C/C++ runtime functions (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9232
diff
changeset
|
173 static void new_array(JavaThread* thread, Klass* klass, jint length); |
9355
4e260c2ced0e
removed new_multi_array assembler stub (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9354
diff
changeset
|
174 static void new_multi_array(JavaThread* thread, Klass* klass, int rank, jint* dims); |
12423
370b5f07f9e2
The runtime entries need to use oopDesc* rather than oop in their signature
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
10953
diff
changeset
|
175 static void dynamic_new_array(JavaThread* thread, oopDesc* element_mirror, jint length); |
13578
d8143c431d63
Add DynamicNewInstanceNode and use it to intrinsify Unsafe.allocateInstance
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
12435
diff
changeset
|
176 static void dynamic_new_instance(JavaThread* thread, oopDesc* type_mirror); |
12423
370b5f07f9e2
The runtime entries need to use oopDesc* rather than oop in their signature
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
10953
diff
changeset
|
177 static jboolean thread_is_interrupted(JavaThread* thread, oopDesc* obj, jboolean clear_interrupted); |
9471
5fa54bf57f8c
replaced exception_handler_nofpu assembler stub with a compiled stub (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9463
diff
changeset
|
178 static void vm_message(jboolean vmError, jlong format, jlong v1, jlong v2, jlong v3); |
12423
370b5f07f9e2
The runtime entries need to use oopDesc* rather than oop in their signature
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
10953
diff
changeset
|
179 static jint identity_hash_code(JavaThread* thread, oopDesc* obj); |
9471
5fa54bf57f8c
replaced exception_handler_nofpu assembler stub with a compiled stub (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9463
diff
changeset
|
180 static address exception_handler_for_pc(JavaThread* thread); |
9590
5f9c41cd3b1e
replaced monitorenter/monitorexit assembler stubs with compiled stubs (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9581
diff
changeset
|
181 static void monitorenter(JavaThread* thread, oopDesc* obj, BasicLock* lock); |
5f9c41cd3b1e
replaced monitorenter/monitorexit assembler stubs with compiled stubs (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9581
diff
changeset
|
182 static void monitorexit (JavaThread* thread, oopDesc* obj, BasicLock* lock); |
14731
0cb5c4d276d4
use raw data support to fix incorrect use of String.intern() for embedding strings in code
Doug Simon <doug.simon@oracle.com>
parents:
13578
diff
changeset
|
183 static void vm_error(JavaThread* thread, jlong where, jlong format, jlong value); |
12423
370b5f07f9e2
The runtime entries need to use oopDesc* rather than oop in their signature
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
10953
diff
changeset
|
184 static oopDesc* load_and_clear_exception(JavaThread* thread); |
370b5f07f9e2
The runtime entries need to use oopDesc* rather than oop in their signature
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
10953
diff
changeset
|
185 static void log_printf(JavaThread* thread, oopDesc* format, jlong v1, jlong v2, jlong v3); |
9592
efb8c1918ea5
replaced create_out_of_bounds_exception assembler stub with compiled stub (GRAAL-81)
Doug Simon <doug.simon@oracle.com>
parents:
9591
diff
changeset
|
186 static void log_primitive(JavaThread* thread, jchar typeChar, jlong value, jboolean newline); |
22668
da5bdbf4a008
Simplify log_object interface
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22650
diff
changeset
|
187 // Print the passed in object, optionally followed by a newline. If |
da5bdbf4a008
Simplify log_object interface
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22650
diff
changeset
|
188 // as_string is true and the object is a java.lang.String then it |
da5bdbf4a008
Simplify log_object interface
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22650
diff
changeset
|
189 // printed as a string, otherwise the type of the object is printed |
da5bdbf4a008
Simplify log_object interface
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22650
diff
changeset
|
190 // followed by its address. |
da5bdbf4a008
Simplify log_object interface
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
22650
diff
changeset
|
191 static void log_object(JavaThread* thread, oopDesc* object, bool as_string, bool newline); |
10434
8b22524df53b
Add G1 Barriers' foreign calls
Christos Kotselidis <christos.kotselidis@oracle.com>
parents:
10072
diff
changeset
|
192 static void write_barrier_pre(JavaThread* thread, oopDesc* obj); |
8b22524df53b
Add G1 Barriers' foreign calls
Christos Kotselidis <christos.kotselidis@oracle.com>
parents:
10072
diff
changeset
|
193 static void write_barrier_post(JavaThread* thread, void* card); |
10953
97e282186b5b
Add heap sanity checker with premature hard crash for debugging write barriers
Christos Kotselidis <christos.kotselidis@oracle.com>
parents:
10770
diff
changeset
|
194 static jboolean validate_object(JavaThread* thread, oopDesc* parent, oopDesc* child); |
12433
808348377021
Fix inconsistent oops in slow path allocation
Christos Kotselidis <christos.kotselidis@oracle.com>
parents:
10953
diff
changeset
|
195 static void new_store_pre_barrier(JavaThread* thread); |
18227
bcb1e5c232d8
Test deoptimization inside ForeignCallNode
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
17033
diff
changeset
|
196 |
23334
e0a15983ab51
Create exception throwing routines for exceptions with complex messages.
Roland Schatz <roland.schatz@oracle.com>
parents:
23329
diff
changeset
|
197 // used to throw exceptions from compiled JVMCI code |
23367
041534002323
Use strings instead of Symbol* for exception names (JDK-8155735).
Roland Schatz <roland.schatz@oracle.com>
parents:
23337
diff
changeset
|
198 static void throw_and_post_jvmti_exception(JavaThread* thread, const char* exception, const char* message); |
23334
e0a15983ab51
Create exception throwing routines for exceptions with complex messages.
Roland Schatz <roland.schatz@oracle.com>
parents:
23329
diff
changeset
|
199 // helper methods to throw exception with complex messages |
23367
041534002323
Use strings instead of Symbol* for exception names (JDK-8155735).
Roland Schatz <roland.schatz@oracle.com>
parents:
23337
diff
changeset
|
200 static void throw_klass_external_name_exception(JavaThread* thread, const char* exception, Klass* klass); |
041534002323
Use strings instead of Symbol* for exception names (JDK-8155735).
Roland Schatz <roland.schatz@oracle.com>
parents:
23337
diff
changeset
|
201 static void throw_class_cast_exception(JavaThread* thread, const char* exception, Klass* caster_klass, Klass* target_klass); |
23334
e0a15983ab51
Create exception throwing routines for exceptions with complex messages.
Roland Schatz <roland.schatz@oracle.com>
parents:
23329
diff
changeset
|
202 |
18227
bcb1e5c232d8
Test deoptimization inside ForeignCallNode
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
17033
diff
changeset
|
203 // Test only function |
bcb1e5c232d8
Test deoptimization inside ForeignCallNode
Tom Rodriguez <tom.rodriguez@oracle.com>
parents:
17033
diff
changeset
|
204 static int test_deoptimize_call_int(JavaThread* thread, int value); |
7125
1baf7f1e3f23
decoupled C++ Graal runtime from C1
Doug Simon <doug.simon@oracle.com>
parents:
6559
diff
changeset
|
205 }; |
1baf7f1e3f23
decoupled C++ Graal runtime from C1
Doug Simon <doug.simon@oracle.com>
parents:
6559
diff
changeset
|
206 |
22544
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
207 // Tracing macros. |
15582
063ec2920d21
made Graal runtime initialization in hosted mode lazy
Doug Simon <doug.simon@oracle.com>
parents:
14731
diff
changeset
|
208 |
22544
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
209 #define IF_TRACE_jvmci_1 if (!(JVMCITraceLevel >= 1)) ; else |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
210 #define IF_TRACE_jvmci_2 if (!(JVMCITraceLevel >= 2)) ; else |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
211 #define IF_TRACE_jvmci_3 if (!(JVMCITraceLevel >= 3)) ; else |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
212 #define IF_TRACE_jvmci_4 if (!(JVMCITraceLevel >= 4)) ; else |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
213 #define IF_TRACE_jvmci_5 if (!(JVMCITraceLevel >= 5)) ; else |
15582
063ec2920d21
made Graal runtime initialization in hosted mode lazy
Doug Simon <doug.simon@oracle.com>
parents:
14731
diff
changeset
|
214 |
22544
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
215 #define TRACE_jvmci_1 if (!(JVMCITraceLevel >= 1 && (tty->print("JVMCITrace-1: "), true))) ; else tty->print_cr |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
216 #define TRACE_jvmci_2 if (!(JVMCITraceLevel >= 2 && (tty->print(" JVMCITrace-2: "), true))) ; else tty->print_cr |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
217 #define TRACE_jvmci_3 if (!(JVMCITraceLevel >= 3 && (tty->print(" JVMCITrace-3: "), true))) ; else tty->print_cr |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
218 #define TRACE_jvmci_4 if (!(JVMCITraceLevel >= 4 && (tty->print(" JVMCITrace-4: "), true))) ; else tty->print_cr |
b87d1bf3cd9a
renamed TraceJVMCI option to JVMCITraceLevel and ensured all tracing controlled by this option uses the TRACE_jvmci_* macros
Doug Simon <doug.simon@oracle.com>
parents:
22538
diff
changeset
|
219 #define TRACE_jvmci_5 if (!(JVMCITraceLevel >= 5 && (tty->print(" JVMCITrace-5: "), true))) ; else tty->print_cr |
15582
063ec2920d21
made Graal runtime initialization in hosted mode lazy
Doug Simon <doug.simon@oracle.com>
parents:
14731
diff
changeset
|
220 |
21559
be896a1983c0
recast all Graal native code as JVMCI code (JBS:GRAAL-53)
Doug Simon <doug.simon@oracle.com>
parents:
21527
diff
changeset
|
221 #endif // SHARE_VM_JVMCI_JVMCI_RUNTIME_HPP |