< prev index next >

src/hotspot/share/prims/jvmtiExport.cpp

Print this page
rev 47287 : Port 09.17.Thread_SMR_logging_update from JDK9 to JDK10
rev 47289 : eosterlund, stefank CR - refactor code into threadSMR.cpp and threadSMR.hpp
rev 47292 : stefank, coleenp CR - refactor most JavaThreadIterator usage to use JavaThreadIteratorWithHandle.

@@ -2786,13 +2786,11 @@
   // no-op if jvmti not enabled
   if (!JvmtiEnv::environments_might_exist()) {
     return;
   }
 
-  ThreadsListHandle tlh;
-  JavaThreadIterator jti(tlh.list());
-  for (JavaThread *jthr = jti.first(); jthr != NULL; jthr = jti.next()) {
+  for (JavaThreadIteratorWithHandle jtiwh; JavaThread *jthr = jtiwh.next(); ) {
     JvmtiThreadState *state = jthr->jvmti_thread_state();
     if (state != NULL) {
       JvmtiVMObjectAllocEventCollector *collector;
       collector = state->get_vm_object_alloc_event_collector();
       while (collector != NULL) {
< prev index next >