< prev index next >

src/share/vm/prims/forte.cpp

Print this page
rev 12854 : [mq]: gcinterface.patch


 529 
 530     // bad env_id, thread has exited or thread is exiting
 531     trace->num_frames = ticks_thread_exit; // -8
 532     return;
 533   }
 534 
 535   if (thread->in_deopt_handler()) {
 536     // thread is in the deoptimization handler so return no frames
 537     trace->num_frames = ticks_deopt; // -9
 538     return;
 539   }
 540 
 541   assert(JavaThread::current() == thread,
 542          "AsyncGetCallTrace must be called by the current interrupted thread");
 543 
 544   if (!JvmtiExport::should_post_class_load()) {
 545     trace->num_frames = ticks_no_class_load; // -1
 546     return;
 547   }
 548 
 549   if (Universe::heap()->is_gc_active()) {
 550     trace->num_frames = ticks_GC_active; // -2
 551     return;
 552   }
 553 
 554   switch (thread->thread_state()) {
 555   case _thread_new:
 556   case _thread_uninitialized:
 557   case _thread_new_trans:
 558     // We found the thread on the threads list above, but it is too
 559     // young to be useful so return that there are no Java frames.
 560     trace->num_frames = 0;
 561     break;
 562   case _thread_in_native:
 563   case _thread_in_native_trans:
 564   case _thread_blocked:
 565   case _thread_blocked_trans:
 566   case _thread_in_vm:
 567   case _thread_in_vm_trans:
 568     {
 569       frame fr;




 529 
 530     // bad env_id, thread has exited or thread is exiting
 531     trace->num_frames = ticks_thread_exit; // -8
 532     return;
 533   }
 534 
 535   if (thread->in_deopt_handler()) {
 536     // thread is in the deoptimization handler so return no frames
 537     trace->num_frames = ticks_deopt; // -9
 538     return;
 539   }
 540 
 541   assert(JavaThread::current() == thread,
 542          "AsyncGetCallTrace must be called by the current interrupted thread");
 543 
 544   if (!JvmtiExport::should_post_class_load()) {
 545     trace->num_frames = ticks_no_class_load; // -1
 546     return;
 547   }
 548 
 549   if (GC::gc()->heap()->is_gc_active()) {
 550     trace->num_frames = ticks_GC_active; // -2
 551     return;
 552   }
 553 
 554   switch (thread->thread_state()) {
 555   case _thread_new:
 556   case _thread_uninitialized:
 557   case _thread_new_trans:
 558     // We found the thread on the threads list above, but it is too
 559     // young to be useful so return that there are no Java frames.
 560     trace->num_frames = 0;
 561     break;
 562   case _thread_in_native:
 563   case _thread_in_native_trans:
 564   case _thread_blocked:
 565   case _thread_blocked_trans:
 566   case _thread_in_vm:
 567   case _thread_in_vm_trans:
 568     {
 569       frame fr;


< prev index next >