src/hotspot/share/runtime/thread.cpp
changeset 54278 16999bd91ba6
parent 54259 d25b24c70126
child 54291 e6c86f6012bf
equal deleted inserted replaced
54277:f283f6871336 54278:16999bd91ba6
  2926   if (jvmti_thread_state() != NULL) {
  2926   if (jvmti_thread_state() != NULL) {
  2927     jvmti_thread_state()->oops_do(f);
  2927     jvmti_thread_state()->oops_do(f);
  2928   }
  2928   }
  2929 }
  2929 }
  2930 
  2930 
       
  2931 #ifdef ASSERT
       
  2932 void JavaThread::verify_states_for_handshake() {
       
  2933   // This checks that the thread has a correct frame state during a handshake.
       
  2934   assert((!has_last_Java_frame() && java_call_counter() == 0) ||
       
  2935          (has_last_Java_frame() && java_call_counter() > 0),
       
  2936          "unexpected frame info: has_last_frame=%d, java_call_counter=%d",
       
  2937          has_last_Java_frame(), java_call_counter());
       
  2938 }
       
  2939 #endif
       
  2940 
  2931 void JavaThread::nmethods_do(CodeBlobClosure* cf) {
  2941 void JavaThread::nmethods_do(CodeBlobClosure* cf) {
  2932   assert((!has_last_Java_frame() && java_call_counter() == 0) ||
  2942   assert((!has_last_Java_frame() && java_call_counter() == 0) ||
  2933          (has_last_Java_frame() && java_call_counter() > 0), "wrong java_sp info!");
  2943          (has_last_Java_frame() && java_call_counter() > 0),
       
  2944          "unexpected frame info: has_last_frame=%d, java_call_counter=%d",
       
  2945          has_last_Java_frame(), java_call_counter());
  2934 
  2946 
  2935   if (has_last_Java_frame()) {
  2947   if (has_last_Java_frame()) {
  2936     // Traverse the execution stack
  2948     // Traverse the execution stack
  2937     for (StackFrameStream fst(this); !fst.is_done(); fst.next()) {
  2949     for (StackFrameStream fst(this); !fst.is_done(); fst.next()) {
  2938       fst.current()->nmethods_do(cf);
  2950       fst.current()->nmethods_do(cf);