equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
38 #include "memory/resourceArea.hpp" |
38 #include "memory/resourceArea.hpp" |
39 #include "oops/oop.inline.hpp" |
39 #include "oops/oop.inline.hpp" |
40 #include "oops/objArrayOop.inline.hpp" |
40 #include "oops/objArrayOop.inline.hpp" |
41 #include "runtime/biasedLocking.hpp" |
41 #include "runtime/biasedLocking.hpp" |
42 #include "runtime/interfaceSupport.hpp" |
42 #include "runtime/interfaceSupport.hpp" |
|
43 #include "runtime/jniHandles.inline.hpp" |
43 #include "runtime/reflection.hpp" |
44 #include "runtime/reflection.hpp" |
44 #include "runtime/sharedRuntime.hpp" |
45 #include "runtime/sharedRuntime.hpp" |
45 #include "runtime/threadSMR.hpp" |
46 #include "runtime/threadSMR.hpp" |
46 #include "utilities/debug.hpp" |
47 #include "utilities/debug.hpp" |
47 #include "utilities/defaultStream.hpp" |
48 #include "utilities/defaultStream.hpp" |
626 JavaCalls::call_static(&result, klass, runtime, sig, CHECK_(Handle())); |
627 JavaCalls::call_static(&result, klass, runtime, sig, CHECK_(Handle())); |
627 } else { |
628 } else { |
628 JavaCalls::call_static(&result, klass, runtime, sig, args, CHECK_(Handle())); |
629 JavaCalls::call_static(&result, klass, runtime, sig, args, CHECK_(Handle())); |
629 } |
630 } |
630 return Handle(THREAD, (oop)result.get_jobject()); |
631 return Handle(THREAD, (oop)result.get_jobject()); |
|
632 } |
|
633 |
|
634 Handle JVMCIRuntime::get_HotSpotJVMCIRuntime(TRAPS) { |
|
635 initialize_JVMCI(CHECK_(Handle())); |
|
636 return Handle(THREAD, JNIHandles::resolve_non_null(_HotSpotJVMCIRuntime_instance)); |
631 } |
637 } |
632 |
638 |
633 void JVMCIRuntime::initialize_HotSpotJVMCIRuntime(TRAPS) { |
639 void JVMCIRuntime::initialize_HotSpotJVMCIRuntime(TRAPS) { |
634 guarantee(!_HotSpotJVMCIRuntime_initialized, "cannot reinitialize HotSpotJVMCIRuntime"); |
640 guarantee(!_HotSpotJVMCIRuntime_initialized, "cannot reinitialize HotSpotJVMCIRuntime"); |
635 JVMCIRuntime::initialize_well_known_classes(CHECK); |
641 JVMCIRuntime::initialize_well_known_classes(CHECK); |