src/hotspot/share/ci/ciMethod.cpp
Index Unified diffs Context diffs Sdiffs Frames Patch New Old Previous File Next File open Sdiff src/hotspot/share/ci

src/hotspot/share/ci/ciMethod.cpp

Print this page




1087   ciEnv* env = CURRENT_ENV;
1088   if (is_c1_compile(env->comp_level())) {
1089     return _is_c1_compilable;
1090   }
1091   return _is_c2_compilable;
1092 }
1093 
1094 // ------------------------------------------------------------------
1095 // ciMethod::set_not_compilable
1096 //
1097 // Tell the VM that this method cannot be compiled at all.
1098 void ciMethod::set_not_compilable(const char* reason) {
1099   check_is_loaded();
1100   VM_ENTRY_MARK;
1101   ciEnv* env = CURRENT_ENV;
1102   if (is_c1_compile(env->comp_level())) {
1103     _is_c1_compilable = false;
1104   } else {
1105     _is_c2_compilable = false;
1106   }
1107   get_Method()->set_not_compilable(env->comp_level(), true, reason);
1108 }
1109 
1110 // ------------------------------------------------------------------
1111 // ciMethod::can_be_osr_compiled
1112 //
1113 // Have previous compilations of this method succeeded?
1114 //
1115 // Implementation note: the VM does not currently keep track
1116 // of failed OSR compilations per bci.  The entry_bci parameter
1117 // is currently unused.
1118 bool ciMethod::can_be_osr_compiled(int entry_bci) {
1119   check_is_loaded();
1120   VM_ENTRY_MARK;
1121   ciEnv* env = CURRENT_ENV;
1122   return !get_Method()->is_not_osr_compilable(env->comp_level());
1123 }
1124 
1125 // ------------------------------------------------------------------
1126 // ciMethod::has_compiled_code
1127 bool ciMethod::has_compiled_code() {




1087   ciEnv* env = CURRENT_ENV;
1088   if (is_c1_compile(env->comp_level())) {
1089     return _is_c1_compilable;
1090   }
1091   return _is_c2_compilable;
1092 }
1093 
1094 // ------------------------------------------------------------------
1095 // ciMethod::set_not_compilable
1096 //
1097 // Tell the VM that this method cannot be compiled at all.
1098 void ciMethod::set_not_compilable(const char* reason) {
1099   check_is_loaded();
1100   VM_ENTRY_MARK;
1101   ciEnv* env = CURRENT_ENV;
1102   if (is_c1_compile(env->comp_level())) {
1103     _is_c1_compilable = false;
1104   } else {
1105     _is_c2_compilable = false;
1106   }
1107   get_Method()->set_not_compilable(reason, env->comp_level());
1108 }
1109 
1110 // ------------------------------------------------------------------
1111 // ciMethod::can_be_osr_compiled
1112 //
1113 // Have previous compilations of this method succeeded?
1114 //
1115 // Implementation note: the VM does not currently keep track
1116 // of failed OSR compilations per bci.  The entry_bci parameter
1117 // is currently unused.
1118 bool ciMethod::can_be_osr_compiled(int entry_bci) {
1119   check_is_loaded();
1120   VM_ENTRY_MARK;
1121   ciEnv* env = CURRENT_ENV;
1122   return !get_Method()->is_not_osr_compilable(env->comp_level());
1123 }
1124 
1125 // ------------------------------------------------------------------
1126 // ciMethod::has_compiled_code
1127 bool ciMethod::has_compiled_code() {


src/hotspot/share/ci/ciMethod.cpp
Index Unified diffs Context diffs Sdiffs Frames Patch New Old Previous File Next File