< prev index next >

src/share/vm/gc/shenandoah/shenandoahConcurrentThread.cpp

Print this page
rev 12117 : Pin regions that contain JNI critical regions, instead of bail-and-retry protocol.

@@ -23,11 +23,10 @@
 
 #include "gc/shared/gcTraceTime.inline.hpp"
 #include "gc/shenandoah/shenandoahConcurrentThread.hpp"
 #include "gc/shenandoah/shenandoahCollectorPolicy.hpp"
 #include "gc/shenandoah/shenandoahHeap.inline.hpp"
-#include "gc/shenandoah/shenandoahJNICritical.hpp"
 #include "gc/shenandoah/shenandoahMonitoringSupport.hpp"
 #include "gc/shenandoah/vm_operations_shenandoah.hpp"
 #include "memory/iterator.hpp"
 #include "memory/universe.hpp"
 #include "runtime/vmThread.hpp"

@@ -64,11 +63,11 @@
         }
 
         TraceCollectorStats tcs(heap->monitoring_support()->full_collection_counters());
         TraceMemoryManagerStats tmms(true, _full_gc_cause);
         VM_ShenandoahFullGC full_gc(_full_gc_cause);
-        heap->jni_critical()->execute_in_vm_thread(&full_gc);
+        VMThread::execute(&full_gc);
       }
       MonitorLockerEx ml(&_full_gc_lock);
       _do_full_gc = false;
       ml.notify_all();
     } else if (heap->shenandoahPolicy()->should_start_concurrent_mark(heap->used(),

@@ -101,11 +100,11 @@
 
         {
           TraceCollectorStats tcs(heap->monitoring_support()->stw_collection_counters());
           VM_ShenandoahStartEvacuation finishMark;
           heap->shenandoahPolicy()->record_phase_start(ShenandoahCollectorPolicy::final_mark_gross);
-          heap->jni_critical()->execute_in_vm_thread(&finishMark);
+          VMThread::execute(&finishMark);
           heap->shenandoahPolicy()->record_phase_end(ShenandoahCollectorPolicy::final_mark_gross);
         }
 
         if (! should_terminate()) {
           GCTraceTime(Info, gc, phases) time("Concurrent evacuation", gc_timer, GCCause::_no_gc, true);
< prev index next >