< prev index next >

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

Print this page
rev 14282 : Factor out keep-alive barrier from usual pre-barrier implementations.

@@ -397,10 +397,16 @@
     return resolve_oop_static(obj);
   }
   return obj;
 }
 
+void ShenandoahBarrierSet::keep_alive_barrier(oop obj) {
+  if (ShenandoahKeepAliveBarrier) {
+    G1SATBCardTableModRefBS::enqueue(obj);
+  }
+}
+
 #ifdef ASSERT
 void ShenandoahBarrierSet::verify_safe_oop(oop p) {
   ShenandoahHeap* heap = ShenandoahHeap::heap();
   if (p == NULL) return;
   if (heap->in_collection_set(p) &&
< prev index next >