diff src/share/vm/code/nmethod.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 2a47bd84841f
children d2ede61b7a12
line wrap: on
line diff
--- a/src/share/vm/code/nmethod.cpp	Tue Aug 10 12:15:10 2010 -0700
+++ b/src/share/vm/code/nmethod.cpp	Wed Aug 11 01:17:27 2010 -0700
@@ -2472,8 +2472,12 @@
   if (block_begin == exception_begin())         stream->print_cr("[Exception Handler]");
   if (block_begin == stub_begin())              stream->print_cr("[Stub Code]");
   if (block_begin == deopt_handler_begin())     stream->print_cr("[Deopt Handler Code]");
-  if (block_begin == deopt_mh_handler_begin())  stream->print_cr("[Deopt MH Handler Code]");
+
+  if (has_method_handle_invokes())
+    if (block_begin == deopt_mh_handler_begin())  stream->print_cr("[Deopt MH Handler Code]");
+
   if (block_begin == consts_begin())            stream->print_cr("[Constants]");
+
   if (block_begin == entry_point()) {
     methodHandle m = method();
     if (m.not_null()) {