< prev index next >
src/share/vm/runtime/vmThread.cpp
Print this page
*** 23,32 ****
--- 23,34 ----
*/
#include "precompiled.hpp"
#include "compiler/compileBroker.hpp"
#include "gc/shared/collectedHeap.hpp"
+ #include "logging/log.hpp"
+ #include "logging/logConfiguration.hpp"
#include "memory/resourceArea.hpp"
#include "oops/method.hpp"
#include "oops/oop.inline.hpp"
#include "oops/verifyOopClosure.hpp"
#include "runtime/interfaceSupport.hpp"
*** 482,491 ****
--- 484,494 ----
os::hint_no_preempt();
// If we are at a safepoint we will evaluate all the operations that
// follow that also require a safepoint
if (_cur_vm_operation->evaluate_at_safepoint()) {
+ log_debug(vmthread)("Evaluating safepoint VM operation: %s", _cur_vm_operation->name());
_vm_queue->set_drain_list(safepoint_ops); // ensure ops can be scanned
SafepointSynchronize::begin();
evaluate_operation(_cur_vm_operation);
*** 493,502 ****
--- 496,506 ----
// the queue until there are none left
do {
_cur_vm_operation = safepoint_ops;
if (_cur_vm_operation != NULL) {
do {
+ log_debug(vmthread)("Evaluating coalesced safepoint VM operation: %s", _cur_vm_operation->name());
// evaluate_operation deletes the op object so we have
// to grab the next op now
VM_Operation* next = _cur_vm_operation->next();
_vm_queue->set_drain_list(next);
evaluate_operation(_cur_vm_operation);
*** 530,539 ****
--- 534,544 ----
// Complete safepoint synchronization
SafepointSynchronize::end();
} else { // not a safepoint operation
+ log_debug(vmthread)("Evaluating non-safepoint VM operation: %s", _cur_vm_operation->name());
if (TraceLongCompiles) {
elapsedTimer t;
t.start();
evaluate_operation(_cur_vm_operation);
t.stop();
*** 605,614 ****
--- 610,620 ----
// Add VM operation to list of waiting threads. We are guaranteed not to block while holding the
// VMOperationQueue_lock, so we can block without a safepoint check. This allows vm operation requests
// to be queued up during a safepoint synchronization.
{
VMOperationQueue_lock->lock_without_safepoint_check();
+ log_debug(vmthread)("Adding VM operation: %s", op->name());
bool ok = _vm_queue->add(op);
op->set_timestamp(os::javaTimeMillis());
VMOperationQueue_lock->notify();
VMOperationQueue_lock->unlock();
// VM_Operation got skipped
< prev index next >