< prev index next >

src/hotspot/cpu/ppc/methodHandles_ppc.cpp

Print this page
*** 305,10 ***
--- 305,16 ---
    }
  
    return entry_point;
  }
  
+ void MethodHandles::jump_to_native_invoker(MacroAssembler* _masm, Register nep_reg, Register temp_target) {
+   BLOCK_COMMENT("jump_to_native_invoker {");
+   __ stop("Should not reach here");
+   BLOCK_COMMENT("} jump_to_native_invoker");
+ }
+ 
  void MethodHandles::generate_method_handle_dispatch(MacroAssembler* _masm,
                                                      vmIntrinsics::ID iid,
                                                      Register receiver_reg,
                                                      Register member_reg,
                                                      bool for_compiler_entry) {

*** 322,16 ***
  
    const MacroAssembler::PreservationLevel preservation_level = for_compiler_entry
      ? MacroAssembler::PRESERVATION_FRAME_LR_GP_FP_REGS
      : MacroAssembler::PRESERVATION_FRAME_LR;
  
!   if (iid == vmIntrinsics::_invokeBasic || iid == vmIntrinsics::_linkToNative) {
-     if (iid == vmIntrinsics::_linkToNative) {
-       assert(for_compiler_entry, "only compiler entry is supported");
-     }
      // indirect through MH.form.vmentry.vmtarget
      jump_to_lambda_form(_masm, receiver_reg, R19_method, temp1, temp2, for_compiler_entry);
    } else {
      // The method is a member invoker used by direct method handles.
      if (VerifyMethodHandles) {
        // make sure the trailing argument really is a MemberName (caller responsibility)
        verify_klass(_masm, member_reg, VM_CLASS_ID(MemberName_klass),
--- 328,16 ---
  
    const MacroAssembler::PreservationLevel preservation_level = for_compiler_entry
      ? MacroAssembler::PRESERVATION_FRAME_LR_GP_FP_REGS
      : MacroAssembler::PRESERVATION_FRAME_LR;
  
!   if (iid == vmIntrinsics::_invokeBasic) {
      // indirect through MH.form.vmentry.vmtarget
      jump_to_lambda_form(_masm, receiver_reg, R19_method, temp1, temp2, for_compiler_entry);
+   } else if (iid == vmIntrinsics::_linkToNative) {
+     assert(for_compiler_entry, "only compiler entry is supported");
+     jump_to_native_invoker(_masm, member_reg, temp1);
    } else {
      // The method is a member invoker used by direct method handles.
      if (VerifyMethodHandles) {
        // make sure the trailing argument really is a MemberName (caller responsibility)
        verify_klass(_masm, member_reg, VM_CLASS_ID(MemberName_klass),
< prev index next >