< prev index next >

src/hotspot/share/gc/shenandoah/shenandoahRuntime.cpp

Print this page




  39 }
  40 
  41 void ShenandoahRuntime::write_ref_array_post_entry(HeapWord* dst, size_t length) {
  42   ShenandoahBarrierSet *bs = ShenandoahBarrierSet::barrier_set();
  43   bs->ShenandoahBarrierSet::write_ref_array(dst, length);
  44 }
  45 
  46 // Shenandoah pre write barrier slowpath
  47 JRT_LEAF(void, ShenandoahRuntime::write_ref_field_pre_entry(oopDesc* orig, JavaThread *thread))
  48   if (orig == NULL) {
  49     assert(false, "should be optimized out");
  50     return;
  51   }
  52   shenandoah_assert_correct(NULL, orig);
  53   // store the original value that was in the field reference
  54   assert(ShenandoahThreadLocalData::satb_mark_queue(thread).is_active(), "Shouldn't be here otherwise");
  55   ShenandoahThreadLocalData::satb_mark_queue(thread).enqueue_known_active(orig);
  56 JRT_END
  57 
  58 JRT_LEAF(oopDesc*, ShenandoahRuntime::load_reference_barrier_JRT(oopDesc* src))
  59   oop result = ShenandoahBarrierSet::barrier_set()->load_reference_barrier_mutator(src);
  60   return (oopDesc*) result;







  61 JRT_END
  62 
  63 // Shenandoah clone barrier: makes sure that references point to to-space
  64 // in cloned objects.
  65 JRT_LEAF(void, ShenandoahRuntime::shenandoah_clone_barrier(oopDesc* obj))
  66   ShenandoahBarrierSet::barrier_set()->write_region(MemRegion((HeapWord*) obj, obj->size()));
  67 JRT_END


  39 }
  40 
  41 void ShenandoahRuntime::write_ref_array_post_entry(HeapWord* dst, size_t length) {
  42   ShenandoahBarrierSet *bs = ShenandoahBarrierSet::barrier_set();
  43   bs->ShenandoahBarrierSet::write_ref_array(dst, length);
  44 }
  45 
  46 // Shenandoah pre write barrier slowpath
  47 JRT_LEAF(void, ShenandoahRuntime::write_ref_field_pre_entry(oopDesc* orig, JavaThread *thread))
  48   if (orig == NULL) {
  49     assert(false, "should be optimized out");
  50     return;
  51   }
  52   shenandoah_assert_correct(NULL, orig);
  53   // store the original value that was in the field reference
  54   assert(ShenandoahThreadLocalData::satb_mark_queue(thread).is_active(), "Shouldn't be here otherwise");
  55   ShenandoahThreadLocalData::satb_mark_queue(thread).enqueue_known_active(orig);
  56 JRT_END
  57 
  58 JRT_LEAF(oopDesc*, ShenandoahRuntime::load_reference_barrier_JRT(oopDesc* src))
  59   return ShenandoahBarrierSet::barrier_set()->load_reference_barrier_mutator(src, (oop*)NULL);
  60 JRT_END
  61 
  62 JRT_LEAF(oopDesc*, ShenandoahRuntime::load_reference_barrier_fixup_JRT(oopDesc* src, oop* load_addr))
  63   return ShenandoahBarrierSet::barrier_set()->load_reference_barrier_mutator(src, load_addr);
  64 JRT_END
  65 
  66 JRT_LEAF(oopDesc*, ShenandoahRuntime::load_reference_barrier_fixup_narrow_JRT(oopDesc* src, narrowOop* load_addr))
  67   return ShenandoahBarrierSet::barrier_set()->load_reference_barrier_mutator(src, load_addr);
  68 JRT_END
  69 
  70 // Shenandoah clone barrier: makes sure that references point to to-space
  71 // in cloned objects.
  72 JRT_LEAF(void, ShenandoahRuntime::shenandoah_clone_barrier(oopDesc* obj))
  73   ShenandoahBarrierSet::barrier_set()->write_region(MemRegion((HeapWord*) obj, obj->size()));
  74 JRT_END
< prev index next >