< prev index next >
src/hotspot/share/runtime/sweeper.cpp
Print this page
rev 57079 : [mq]: handshake-logs
*** 309,318 ****
--- 309,328 ----
}
return &set_hotness_closure;
}
+ class NMethodMarkingHandshake : public HandshakeOperation {
+ NMethodMarkingThreadClosure* _cl;
+ public:
+ NMethodMarkingHandshake(NMethodMarkingThreadClosure* cl) : _cl(cl) {}
+ const char* name() { return "NMethodMarking";};
+ void do_thread(JavaThread* jt) {
+ _cl->do_thread(jt);
+ }
+ };
+
/**
* This function triggers a VM operation that does stack scanning of active
* methods. Stack scanning is mandatory for the sweeper to make progress.
*/
void NMethodSweeper::do_stack_scanning() {
*** 324,334 ****
MutexLocker ccl(CodeCache_lock, Mutex::_no_safepoint_check_flag);
code_cl = prepare_mark_active_nmethods();
}
if (code_cl != NULL) {
NMethodMarkingThreadClosure tcl(code_cl);
! Handshake::execute(&tcl);
}
} else {
VM_MarkActiveNMethods op;
VMThread::execute(&op);
}
--- 334,345 ----
MutexLocker ccl(CodeCache_lock, Mutex::_no_safepoint_check_flag);
code_cl = prepare_mark_active_nmethods();
}
if (code_cl != NULL) {
NMethodMarkingThreadClosure tcl(code_cl);
! NMethodMarkingHandshake nm_hs(&tcl);
! Handshake::execute(&nm_hs);
}
} else {
VM_MarkActiveNMethods op;
VMThread::execute(&op);
}
< prev index next >