comparison src/share/vm/c1/c1_Compilation.cpp @ 1691:4a665be40fd3

6975855: don't emit deopt MH handler in C1 if not required Summary: This CR implements the same for C1 as 6926782 for C2. Reviewed-by: never
author twisti
date Wed, 11 Aug 2010 01:17:27 -0700
parents 9887b5e57f9e
children 3e8fbc61cee8
comparison
equal deleted inserted replaced
1690:36519c19beeb 1691:4a665be40fd3
218 218
219 // Generate code for deopt handler. 219 // Generate code for deopt handler.
220 code_offsets->set_value(CodeOffsets::Deopt, assembler->emit_deopt_handler()); 220 code_offsets->set_value(CodeOffsets::Deopt, assembler->emit_deopt_handler());
221 CHECK_BAILOUT(); 221 CHECK_BAILOUT();
222 222
223 // Generate code for MethodHandle deopt handler. We can use the 223 // Emit the MethodHandle deopt handler code (if required).
224 // same code as for the normal deopt handler, we just need a 224 if (has_method_handle_invokes()) {
225 // different entry point address. 225 // We can use the same code as for the normal deopt handler, we
226 code_offsets->set_value(CodeOffsets::DeoptMH, assembler->emit_deopt_handler()); 226 // just need a different entry point address.
227 CHECK_BAILOUT(); 227 code_offsets->set_value(CodeOffsets::DeoptMH, assembler->emit_deopt_handler());
228 CHECK_BAILOUT();
229 }
228 230
229 // Emit the handler to remove the activation from the stack and 231 // Emit the handler to remove the activation from the stack and
230 // dispatch to the caller. 232 // dispatch to the caller.
231 offsets()->set_value(CodeOffsets::UnwindHandler, assembler->emit_unwind_handler()); 233 offsets()->set_value(CodeOffsets::UnwindHandler, assembler->emit_unwind_handler());
232 234
444 , _frame_map(NULL) 446 , _frame_map(NULL)
445 , _masm(NULL) 447 , _masm(NULL)
446 , _has_exception_handlers(false) 448 , _has_exception_handlers(false)
447 , _has_fpu_code(true) // pessimistic assumption 449 , _has_fpu_code(true) // pessimistic assumption
448 , _has_unsafe_access(false) 450 , _has_unsafe_access(false)
451 , _has_method_handle_invokes(false)
449 , _bailout_msg(NULL) 452 , _bailout_msg(NULL)
450 , _exception_info_list(NULL) 453 , _exception_info_list(NULL)
451 , _allocator(NULL) 454 , _allocator(NULL)
452 , _next_id(0) 455 , _next_id(0)
453 , _next_block_id(0) 456 , _next_block_id(0)