src/hotspot/share/services/memoryPool.hpp
changeset 49658 8237a91c1cca
parent 48168 cb5d2d4453d0
child 51497 ec014e5694ec
equal deleted inserted replaced
49657:45071514f87a 49658:8237a91c1cca
    24 
    24 
    25 #ifndef SHARE_VM_SERVICES_MEMORYPOOL_HPP
    25 #ifndef SHARE_VM_SERVICES_MEMORYPOOL_HPP
    26 #define SHARE_VM_SERVICES_MEMORYPOOL_HPP
    26 #define SHARE_VM_SERVICES_MEMORYPOOL_HPP
    27 
    27 
    28 #include "memory/heap.hpp"
    28 #include "memory/heap.hpp"
       
    29 #include "oops/oop.hpp"
    29 #include "services/memoryUsage.hpp"
    30 #include "services/memoryUsage.hpp"
    30 #include "utilities/macros.hpp"
    31 #include "utilities/macros.hpp"
    31 
    32 
    32 // A memory pool represents the memory area that the VM manages.
    33 // A memory pool represents the memory area that the VM manages.
    33 // The Java virtual machine has at least one memory pool
    34 // The Java virtual machine has at least one memory pool
    90   size_t      initial_size()   const       { return _initial_size; }
    91   size_t      initial_size()   const       { return _initial_size; }
    91   int         num_memory_managers() const  { return _num_managers; }
    92   int         num_memory_managers() const  { return _num_managers; }
    92   // max size could be changed
    93   // max size could be changed
    93   virtual size_t max_size()    const       { return _max_size; }
    94   virtual size_t max_size()    const       { return _max_size; }
    94 
    95 
    95   bool is_pool(instanceHandle pool) { return (pool() == _memory_pool_obj); }
    96   bool is_pool(instanceHandle pool) { return oopDesc::equals(pool(), _memory_pool_obj); }
    96 
    97 
    97   bool available_for_allocation()   { return _available_for_allocation; }
    98   bool available_for_allocation()   { return _available_for_allocation; }
    98   bool set_available_for_allocation(bool value) {
    99   bool set_available_for_allocation(bool value) {
    99     bool prev = _available_for_allocation;
   100     bool prev = _available_for_allocation;
   100     _available_for_allocation = value;
   101     _available_for_allocation = value;