< prev index next >

src/hotspot/share/gc/g1/g1CollectedHeap.inline.hpp

Print this page




  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_GC_G1_G1COLLECTEDHEAP_INLINE_HPP
  26 #define SHARE_GC_G1_G1COLLECTEDHEAP_INLINE_HPP
  27 
  28 #include "gc/g1/g1BarrierSet.hpp"
  29 #include "gc/g1/g1CollectedHeap.hpp"
  30 #include "gc/g1/g1CollectorState.hpp"
  31 #include "gc/g1/g1Policy.hpp"
  32 #include "gc/g1/g1RemSet.hpp"
  33 #include "gc/g1/heapRegionManager.inline.hpp"
  34 #include "gc/g1/heapRegionRemSet.hpp"
  35 #include "gc/g1/heapRegionSet.inline.hpp"
  36 #include "gc/shared/taskqueue.inline.hpp"
  37 #include "runtime/orderAccess.hpp"
  38 
  39 G1GCPhaseTimes* G1CollectedHeap::phase_times() const {
  40   return _policy->phase_times();
  41 }
  42 
  43 G1EvacStats* G1CollectedHeap::alloc_buffer_stats(G1HeapRegionAttr dest) {
  44   switch (dest.type()) {
  45     case G1HeapRegionAttr::Young:
  46       return &_survivor_evac_stats;
  47     case G1HeapRegionAttr::Old:
  48       return &_old_evac_stats;
  49     default:
  50       ShouldNotReachHere();
  51       return NULL; // Keep some compilers happy
  52   }
  53 }
  54 
  55 size_t G1CollectedHeap::desired_plab_sz(G1HeapRegionAttr dest) {
  56   size_t gclab_word_size = alloc_buffer_stats(dest)->desired_plab_sz(workers()->active_workers());
  57   // Prevent humongous PLAB sizes for two reasons:




  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_GC_G1_G1COLLECTEDHEAP_INLINE_HPP
  26 #define SHARE_GC_G1_G1COLLECTEDHEAP_INLINE_HPP
  27 
  28 #include "gc/g1/g1BarrierSet.hpp"
  29 #include "gc/g1/g1CollectedHeap.hpp"
  30 #include "gc/g1/g1CollectorState.hpp"
  31 #include "gc/g1/g1Policy.hpp"
  32 #include "gc/g1/g1RemSet.hpp"
  33 #include "gc/g1/heapRegionManager.inline.hpp"
  34 #include "gc/g1/heapRegionRemSet.hpp"
  35 #include "gc/g1/heapRegionSet.inline.hpp"
  36 #include "gc/shared/taskqueue.inline.hpp"

  37 
  38 G1GCPhaseTimes* G1CollectedHeap::phase_times() const {
  39   return _policy->phase_times();
  40 }
  41 
  42 G1EvacStats* G1CollectedHeap::alloc_buffer_stats(G1HeapRegionAttr dest) {
  43   switch (dest.type()) {
  44     case G1HeapRegionAttr::Young:
  45       return &_survivor_evac_stats;
  46     case G1HeapRegionAttr::Old:
  47       return &_old_evac_stats;
  48     default:
  49       ShouldNotReachHere();
  50       return NULL; // Keep some compilers happy
  51   }
  52 }
  53 
  54 size_t G1CollectedHeap::desired_plab_sz(G1HeapRegionAttr dest) {
  55   size_t gclab_word_size = alloc_buffer_stats(dest)->desired_plab_sz(workers()->active_workers());
  56   // Prevent humongous PLAB sizes for two reasons:


< prev index next >