diff src/share/vm/graal/graalCodeInstaller.cpp @ 3538:e4616e3d207b

support for new CiRuntimeCalls CreateNullPointerException and CreateOutOfBoundsException
author Lukas Stadler <lukas.stadler@jku.at>
date Wed, 10 Aug 2011 18:19:09 +0200
parents 5aeb62416609
children 25765a764212
line wrap: on
line diff
--- a/src/share/vm/graal/graalCodeInstaller.cpp	Wed Aug 10 02:13:41 2011 +0200
+++ b/src/share/vm/graal/graalCodeInstaller.cpp	Wed Aug 10 18:19:09 2011 +0200
@@ -594,6 +594,14 @@
       call->set_destination(Runtime1::entry_for(Runtime1::graal_handle_exception_id));
       _instructions->relocate(call->instruction_address(), runtime_call_Relocation::spec(), Assembler::call32_operand);
       TRACE_graal_3("CiRuntimeCall::HandleException()");
+    } else if (runtime_call == CiRuntimeCall::CreateNullPointerException()) {
+      call->set_destination(Runtime1::entry_for(Runtime1::graal_create_null_pointer_exception_id));
+      _instructions->relocate(call->instruction_address(), runtime_call_Relocation::spec(), Assembler::call32_operand);
+      TRACE_graal_3("CiRuntimeCall::CreateNullPointerException()");
+    } else if (runtime_call == CiRuntimeCall::CreateOutOfBoundsException()) {
+      call->set_destination(Runtime1::entry_for(Runtime1::graal_create_out_of_bounds_exception_id));
+      _instructions->relocate(call->instruction_address(), runtime_call_Relocation::spec(), Assembler::call32_operand);
+      TRACE_graal_3("CiRuntimeCall::CreateOutOfBoundsException()");
     } else if (runtime_call == CiRuntimeCall::JavaTimeMillis()) {
       call->set_destination((address)os::javaTimeMillis);
       _instructions->relocate(call->instruction_address(), runtime_call_Relocation::spec(), Assembler::call32_operand);
@@ -658,6 +666,7 @@
       }
       case MARK_INVOKESTATIC: {
         assert(method == NULL || method->is_static(), "cannot call non-static method with invokestatic");
+
         call->set_destination(SharedRuntime::get_resolve_static_call_stub());
         _instructions->relocate(call->instruction_address(), relocInfo::static_call_type, Assembler::call32_operand);
         break;