< prev index next >

src/hotspot/share/prims/whitebox.cpp

Print this page
rev 47862 : imported patch 10.07.open.rebase_20171110.dcubed

@@ -53,10 +53,11 @@
 #include "runtime/interfaceSupport.hpp"
 #include "runtime/javaCalls.hpp"
 #include "runtime/os.hpp"
 #include "runtime/sweeper.hpp"
 #include "runtime/thread.hpp"
+#include "runtime/threadSMR.hpp"
 #include "runtime/vm_version.hpp"
 #include "utilities/align.hpp"
 #include "utilities/debug.hpp"
 #include "utilities/exceptions.hpp"
 #include "utilities/macros.hpp"

@@ -663,11 +664,11 @@
   VM_WhiteBoxDeoptimizeFrames(bool make_not_entrant) :
         _result(0), _make_not_entrant(make_not_entrant) { }
   int  result() const { return _result; }
 
   void doit() {
-    for (JavaThread* t = Threads::first(); t != NULL; t = t->next()) {
+    for (JavaThreadIteratorWithHandle jtiwh; JavaThread *t = jtiwh.next(); ) {
       if (t->has_last_Java_frame()) {
         for (StackFrameStream fst(t, UseBiasedLocking); !fst.is_done(); fst.next()) {
           frame* f = fst.current();
           if (f->can_be_deoptimized() && !f->is_deoptimized_frame()) {
             RegisterMap* reg_map = fst.register_map();
< prev index next >