< prev index next >

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

Print this page

        

*** 599,609 **** JFR_ONLY(ShenandoahJFRSupport::register_jfr_type_serializers()); } size_t ShenandoahHeap::used() const { ! return OrderAccess::load_acquire(&_used); } size_t ShenandoahHeap::committed() const { OrderAccess::acquire(); return _committed; --- 599,609 ---- JFR_ONLY(ShenandoahJFRSupport::register_jfr_type_serializers()); } size_t ShenandoahHeap::used() const { ! return Atomic::load_acquire(&_used); } size_t ShenandoahHeap::committed() const { OrderAccess::acquire(); return _committed;
*** 622,632 **** void ShenandoahHeap::increase_used(size_t bytes) { Atomic::add(bytes, &_used); } void ShenandoahHeap::set_used(size_t bytes) { ! OrderAccess::release_store_fence(&_used, bytes); } void ShenandoahHeap::decrease_used(size_t bytes) { assert(used() >= bytes, "never decrease heap size by more than we've left"); Atomic::sub(bytes, &_used); --- 622,632 ---- void ShenandoahHeap::increase_used(size_t bytes) { Atomic::add(bytes, &_used); } void ShenandoahHeap::set_used(size_t bytes) { ! Atomic::release_store_fence(&_used, bytes); } void ShenandoahHeap::decrease_used(size_t bytes) { assert(used() >= bytes, "never decrease heap size by more than we've left"); Atomic::sub(bytes, &_used);
*** 2112,2126 **** address ShenandoahHeap::gc_state_addr() { return (address) ShenandoahHeap::heap()->_gc_state.addr_of(); } size_t ShenandoahHeap::bytes_allocated_since_gc_start() { ! return OrderAccess::load_acquire(&_bytes_allocated_since_gc_start); } void ShenandoahHeap::reset_bytes_allocated_since_gc_start() { ! OrderAccess::release_store_fence(&_bytes_allocated_since_gc_start, (size_t)0); } void ShenandoahHeap::set_degenerated_gc_in_progress(bool in_progress) { _degenerated_gc_in_progress.set_cond(in_progress); } --- 2112,2126 ---- address ShenandoahHeap::gc_state_addr() { return (address) ShenandoahHeap::heap()->_gc_state.addr_of(); } size_t ShenandoahHeap::bytes_allocated_since_gc_start() { ! return Atomic::load_acquire(&_bytes_allocated_since_gc_start); } void ShenandoahHeap::reset_bytes_allocated_since_gc_start() { ! Atomic::release_store_fence(&_bytes_allocated_since_gc_start, (size_t)0); } void ShenandoahHeap::set_degenerated_gc_in_progress(bool in_progress) { _degenerated_gc_in_progress.set_cond(in_progress); }
< prev index next >