hotspot/src/share/vm/ci/ciMethod.cpp
Print this page
*** 54,66 ****
_code = NULL;
_exception_handlers = NULL;
_liveness = NULL;
_bcea = NULL;
_method_blocks = NULL;
! #ifdef COMPILER2
_flow = NULL;
! #endif // COMPILER2
ciEnv *env = CURRENT_ENV;
if (env->jvmti_can_hotswap_or_post_breakpoint() && _is_compilable) {
// 6328518 check hotswap conditions under the right lock.
MutexLocker locker(Compile_lock);
--- 54,66 ----
_code = NULL;
_exception_handlers = NULL;
_liveness = NULL;
_bcea = NULL;
_method_blocks = NULL;
! #if defined(COMPILER2) || defined(SHARK)
_flow = NULL;
! #endif // COMPILER2 || SHARK
ciEnv *env = CURRENT_ENV;
if (env->jvmti_can_hotswap_or_post_breakpoint() && _is_compilable) {
// 6328518 check hotswap conditions under the right lock.
MutexLocker locker(Compile_lock);
*** 122,134 ****
_liveness = NULL;
_can_be_statically_bound = false;
_bcea = NULL;
_method_blocks = NULL;
_method_data = NULL;
! #ifdef COMPILER2
_flow = NULL;
! #endif // COMPILER2
}
// ------------------------------------------------------------------
// ciMethod::load_code
--- 122,134 ----
_liveness = NULL;
_can_be_statically_bound = false;
_bcea = NULL;
_method_blocks = NULL;
_method_data = NULL;
! #if defined(COMPILER2) || defined(SHARK)
_flow = NULL;
! #endif // COMPILER2 || SHARK
}
// ------------------------------------------------------------------
// ciMethod::load_code
*** 227,236 ****
--- 227,250 ----
VM_ENTRY_MARK;
return get_methodOop()->vtable_index();
}
+ #ifdef SHARK
+ // ------------------------------------------------------------------
+ // ciMethod::itable_index
+ //
+ // Get the position of this method's entry in the itable, if any.
+ int ciMethod::itable_index() {
+ check_is_loaded();
+ assert(holder()->is_linked(), "must be linked");
+ VM_ENTRY_MARK;
+ return klassItable::compute_itable_index(get_methodOop());
+ }
+ #endif // SHARK
+
+
// ------------------------------------------------------------------
// ciMethod::native_entry
//
// Get the address of this method's native code, if any.
address ciMethod::native_entry() {
*** 292,329 ****
// ------------------------------------------------------------------
// ciMethod::get_flow_analysis
ciTypeFlow* ciMethod::get_flow_analysis() {
! #ifdef COMPILER2
if (_flow == NULL) {
ciEnv* env = CURRENT_ENV;
_flow = new (env->arena()) ciTypeFlow(env, this);
_flow->do_flow();
}
return _flow;
! #else // COMPILER2
ShouldNotReachHere();
return NULL;
! #endif // COMPILER2
}
// ------------------------------------------------------------------
// ciMethod::get_osr_flow_analysis
ciTypeFlow* ciMethod::get_osr_flow_analysis(int osr_bci) {
! #ifdef COMPILER2
// OSR entry points are always place after a call bytecode of some sort
assert(osr_bci >= 0, "must supply valid OSR entry point");
ciEnv* env = CURRENT_ENV;
ciTypeFlow* flow = new (env->arena()) ciTypeFlow(env, this, osr_bci);
flow->do_flow();
return flow;
! #else // COMPILER2
ShouldNotReachHere();
return NULL;
! #endif // COMPILER2
}
// ------------------------------------------------------------------
// ciMethod::raw_liveness_at_bci
//
--- 306,343 ----
// ------------------------------------------------------------------
// ciMethod::get_flow_analysis
ciTypeFlow* ciMethod::get_flow_analysis() {
! #if defined(COMPILER2) || defined(SHARK)
if (_flow == NULL) {
ciEnv* env = CURRENT_ENV;
_flow = new (env->arena()) ciTypeFlow(env, this);
_flow->do_flow();
}
return _flow;
! #else // COMPILER2 || SHARK
ShouldNotReachHere();
return NULL;
! #endif // COMPILER2 || SHARK
}
// ------------------------------------------------------------------
// ciMethod::get_osr_flow_analysis
ciTypeFlow* ciMethod::get_osr_flow_analysis(int osr_bci) {
! #if defined(COMPILER2) || defined(SHARK)
// OSR entry points are always place after a call bytecode of some sort
assert(osr_bci >= 0, "must supply valid OSR entry point");
ciEnv* env = CURRENT_ENV;
ciTypeFlow* flow = new (env->arena()) ciTypeFlow(env, this, osr_bci);
flow->do_flow();
return flow;
! #else // COMPILER2 || SHARK
ShouldNotReachHere();
return NULL;
! #endif // COMPILER2 || SHARK
}
// ------------------------------------------------------------------
// ciMethod::raw_liveness_at_bci
//