mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-17 01:24:33 +02:00
8260471: Change SystemDictionary::X_klass calls to vmClasses::X_klass
Reviewed-by: lfoltan, hseigel, dholmes, stuefe
This commit is contained in:
parent
9af333923b
commit
ffbcf1b0a7
191 changed files with 739 additions and 712 deletions
|
@ -30,6 +30,7 @@
|
|||
#include "classfile/javaThreadStatus.hpp"
|
||||
#include "classfile/moduleEntry.hpp"
|
||||
#include "classfile/systemDictionary.hpp"
|
||||
#include "classfile/vmClasses.hpp"
|
||||
#include "classfile/vmSymbols.hpp"
|
||||
#include "code/codeCache.hpp"
|
||||
#include "code/scopeDesc.hpp"
|
||||
|
@ -851,14 +852,14 @@ static void initialize_class(Symbol* class_name, TRAPS) {
|
|||
// Creates the initial ThreadGroup
|
||||
static Handle create_initial_thread_group(TRAPS) {
|
||||
Handle system_instance = JavaCalls::construct_new_instance(
|
||||
SystemDictionary::ThreadGroup_klass(),
|
||||
vmClasses::ThreadGroup_klass(),
|
||||
vmSymbols::void_method_signature(),
|
||||
CHECK_NH);
|
||||
Universe::set_system_thread_group(system_instance());
|
||||
|
||||
Handle string = java_lang_String::create_from_str("main", CHECK_NH);
|
||||
Handle main_instance = JavaCalls::construct_new_instance(
|
||||
SystemDictionary::ThreadGroup_klass(),
|
||||
vmClasses::ThreadGroup_klass(),
|
||||
vmSymbols::threadgroup_string_void_signature(),
|
||||
system_instance,
|
||||
string,
|
||||
|
@ -869,7 +870,7 @@ static Handle create_initial_thread_group(TRAPS) {
|
|||
// Creates the initial Thread, and sets it to running.
|
||||
static void create_initial_thread(Handle thread_group, JavaThread* thread,
|
||||
TRAPS) {
|
||||
InstanceKlass* ik = SystemDictionary::Thread_klass();
|
||||
InstanceKlass* ik = vmClasses::Thread_klass();
|
||||
assert(ik->is_initialized(), "must be");
|
||||
instanceHandle thread_oop = ik->allocate_instance_handle(CHECK);
|
||||
|
||||
|
@ -1047,7 +1048,7 @@ void JavaThread::allocate_threadObj(Handle thread_group, const char* thread_name
|
|||
assert(thread_group.not_null(), "thread group should be specified");
|
||||
assert(threadObj() == NULL, "should only create Java thread object once");
|
||||
|
||||
InstanceKlass* ik = SystemDictionary::Thread_klass();
|
||||
InstanceKlass* ik = vmClasses::Thread_klass();
|
||||
assert(ik->is_initialized(), "must be");
|
||||
instanceHandle thread_oop = ik->allocate_instance_handle(CHECK);
|
||||
|
||||
|
@ -1092,7 +1093,7 @@ void JavaThread::allocate_threadObj(Handle thread_group, const char* thread_name
|
|||
return;
|
||||
}
|
||||
|
||||
Klass* group = SystemDictionary::ThreadGroup_klass();
|
||||
Klass* group = vmClasses::ThreadGroup_klass();
|
||||
Handle threadObj(THREAD, this->threadObj());
|
||||
|
||||
JavaCalls::call_special(&result,
|
||||
|
@ -1862,7 +1863,7 @@ void JavaThread::exit(bool destroy_vm, ExitType exit_type) {
|
|||
if (uncaught_exception.not_null()) {
|
||||
EXCEPTION_MARK;
|
||||
// Call method Thread.dispatchUncaughtException().
|
||||
Klass* thread_klass = SystemDictionary::Thread_klass();
|
||||
Klass* thread_klass = vmClasses::Thread_klass();
|
||||
JavaValue result(T_VOID);
|
||||
JavaCalls::call_virtual(&result,
|
||||
threadObj, thread_klass,
|
||||
|
@ -1889,7 +1890,7 @@ void JavaThread::exit(bool destroy_vm, ExitType exit_type) {
|
|||
while (java_lang_Thread::threadGroup(threadObj()) != NULL && (count-- > 0)) {
|
||||
EXCEPTION_MARK;
|
||||
JavaValue result(T_VOID);
|
||||
Klass* thread_klass = SystemDictionary::Thread_klass();
|
||||
Klass* thread_klass = vmClasses::Thread_klass();
|
||||
JavaCalls::call_virtual(&result,
|
||||
threadObj, thread_klass,
|
||||
vmSymbols::exit_method_name(),
|
||||
|
@ -2147,7 +2148,7 @@ void JavaThread::check_and_handle_async_exceptions(bool check_unsafe_error) {
|
|||
// Check for pending async. exception
|
||||
if (_pending_async_exception != NULL) {
|
||||
// Only overwrite an already pending exception, if it is not a threadDeath.
|
||||
if (!has_pending_exception() || !pending_exception()->is_a(SystemDictionary::ThreadDeath_klass())) {
|
||||
if (!has_pending_exception() || !pending_exception()->is_a(vmClasses::ThreadDeath_klass())) {
|
||||
|
||||
// We cannot call Exceptions::_throw(...) here because we cannot block
|
||||
set_pending_exception(_pending_async_exception, __FILE__, __LINE__);
|
||||
|
@ -2235,7 +2236,7 @@ void JavaThread::send_thread_stop(oop java_throwable) {
|
|||
{
|
||||
// Actually throw the Throwable against the target Thread - however
|
||||
// only if there is no thread death exception installed already.
|
||||
if (_pending_async_exception == NULL || !_pending_async_exception->is_a(SystemDictionary::ThreadDeath_klass())) {
|
||||
if (_pending_async_exception == NULL || !_pending_async_exception->is_a(vmClasses::ThreadDeath_klass())) {
|
||||
// If the topmost frame is a runtime stub, then we are calling into
|
||||
// OptoRuntime from compiled code. Some runtime stubs (new, monitor_exit..)
|
||||
// must deoptimize the caller before continuing, as the compiled exception handler table
|
||||
|
@ -3302,7 +3303,7 @@ void Threads::possibly_parallel_threads_do(bool is_par, ThreadClosure* tc) {
|
|||
// fields in, out, and err. Set up java signal handlers, OS-specific
|
||||
// system settings, and thread group of the main thread.
|
||||
static void call_initPhase1(TRAPS) {
|
||||
Klass* klass = SystemDictionary::System_klass();
|
||||
Klass* klass = vmClasses::System_klass();
|
||||
JavaValue result(T_VOID);
|
||||
JavaCalls::call_static(&result, klass, vmSymbols::initPhase1_name(),
|
||||
vmSymbols::void_method_signature(), CHECK);
|
||||
|
@ -3322,7 +3323,7 @@ static void call_initPhase1(TRAPS) {
|
|||
static void call_initPhase2(TRAPS) {
|
||||
TraceTime timer("Initialize module system", TRACETIME_LOG(Info, startuptime));
|
||||
|
||||
Klass* klass = SystemDictionary::System_klass();
|
||||
Klass* klass = vmClasses::System_klass();
|
||||
|
||||
JavaValue result(T_INT);
|
||||
JavaCallArguments args;
|
||||
|
@ -3344,7 +3345,7 @@ static void call_initPhase2(TRAPS) {
|
|||
// and system class loader may be a custom class loaded from -Xbootclasspath/a,
|
||||
// other modules or the application's classpath.
|
||||
static void call_initPhase3(TRAPS) {
|
||||
Klass* klass = SystemDictionary::System_klass();
|
||||
Klass* klass = vmClasses::System_klass();
|
||||
JavaValue result(T_VOID);
|
||||
JavaCalls::call_static(&result, klass, vmSymbols::initPhase3_name(),
|
||||
vmSymbols::void_method_signature(), CHECK);
|
||||
|
@ -3376,7 +3377,7 @@ void Threads::initialize_java_lang_classes(JavaThread* main_thread, TRAPS) {
|
|||
initialize_class(vmSymbols::java_lang_Module(), CHECK);
|
||||
|
||||
#ifdef ASSERT
|
||||
InstanceKlass *k = SystemDictionary::UnsafeConstants_klass();
|
||||
InstanceKlass *k = vmClasses::UnsafeConstants_klass();
|
||||
assert(k->is_not_initialized(), "UnsafeConstants should not already be initialized");
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue