This commit is contained in:
Christian Thalinger 2016-05-03 19:45:44 +00:00
commit 2898a8c8f0
2 changed files with 12 additions and 9 deletions

View File

@ -425,19 +425,22 @@ JRT_LEAF(void, JVMCIRuntime::monitorexit(JavaThread* thread, oopDesc* obj, Basic
}
JRT_END
JRT_ENTRY(void, JVMCIRuntime::throw_and_post_jvmti_exception(JavaThread* thread, Symbol* name, const char* message))
SharedRuntime::throw_and_post_jvmti_exception(thread, name, message);
JRT_ENTRY(void, JVMCIRuntime::throw_and_post_jvmti_exception(JavaThread* thread, const char* exception, const char* message))
TempNewSymbol symbol = SymbolTable::new_symbol(exception, CHECK);
SharedRuntime::throw_and_post_jvmti_exception(thread, symbol, message);
JRT_END
JRT_ENTRY(void, JVMCIRuntime::throw_klass_external_name_exception(JavaThread* thread, Symbol* exception, Klass* klass))
JRT_ENTRY(void, JVMCIRuntime::throw_klass_external_name_exception(JavaThread* thread, const char* exception, Klass* klass))
ResourceMark rm(thread);
SharedRuntime::throw_and_post_jvmti_exception(thread, exception, klass->external_name());
TempNewSymbol symbol = SymbolTable::new_symbol(exception, CHECK);
SharedRuntime::throw_and_post_jvmti_exception(thread, symbol, klass->external_name());
JRT_END
JRT_ENTRY(void, JVMCIRuntime::throw_class_cast_exception(JavaThread* thread, Symbol* exception, Klass* caster_klass, Klass* target_klass))
JRT_ENTRY(void, JVMCIRuntime::throw_class_cast_exception(JavaThread* thread, const char* exception, Klass* caster_klass, Klass* target_klass))
ResourceMark rm(thread);
const char* message = SharedRuntime::generate_class_cast_message(caster_klass, target_klass);
SharedRuntime::throw_and_post_jvmti_exception(thread, exception, message);
TempNewSymbol symbol = SymbolTable::new_symbol(exception, CHECK);
SharedRuntime::throw_and_post_jvmti_exception(thread, symbol, message);
JRT_END
JRT_LEAF(void, JVMCIRuntime::log_object(JavaThread* thread, oopDesc* obj, bool as_string, bool newline))

View File

@ -156,10 +156,10 @@ class JVMCIRuntime: public AllStatic {
static void new_store_pre_barrier(JavaThread* thread);
// used to throw exceptions from compiled JVMCI code
static void throw_and_post_jvmti_exception(JavaThread* thread, Symbol* exception, const char* message);
static void throw_and_post_jvmti_exception(JavaThread* thread, const char* exception, const char* message);
// helper methods to throw exception with complex messages
static void throw_klass_external_name_exception(JavaThread* thread, Symbol* exception, Klass* klass);
static void throw_class_cast_exception(JavaThread* thread, Symbol* exception, Klass* caster_klass, Klass* target_klass);
static void throw_klass_external_name_exception(JavaThread* thread, const char* exception, Klass* klass);
static void throw_class_cast_exception(JavaThread* thread, const char* exception, Klass* caster_klass, Klass* target_klass);
// Test only function
static int test_deoptimize_call_int(JavaThread* thread, int value);