< prev index next >

src/hotspot/share/gc/g1/heapRegionSet.hpp

Print this page




  51 // asserts are compiled in.
  52 #ifndef HEAP_REGION_SET_FORCE_VERIFY
  53 #define HEAP_REGION_SET_FORCE_VERIFY defined(ASSERT)
  54 #endif // HEAP_REGION_SET_FORCE_VERIFY
  55 
  56 class HRSMtSafeChecker : public CHeapObj<mtGC> {
  57 public:
  58   virtual void check() = 0;
  59 };
  60 
  61 class MasterFreeRegionListMtSafeChecker    : public HRSMtSafeChecker { public: void check(); };
  62 class SecondaryFreeRegionListMtSafeChecker : public HRSMtSafeChecker { public: void check(); };
  63 class HumongousRegionSetMtSafeChecker      : public HRSMtSafeChecker { public: void check(); };
  64 class OldRegionSetMtSafeChecker            : public HRSMtSafeChecker { public: void check(); };
  65 
  66 // Base class for all the classes that represent heap region sets. It
  67 // contains the basic attributes that each set needs to maintain
  68 // (e.g., length, region num, used bytes sum) plus any shared
  69 // functionality (e.g., verification).
  70 
  71 class HeapRegionSetBase VALUE_OBJ_CLASS_SPEC {
  72   friend class VMStructs;
  73 private:
  74   bool _is_humongous;
  75   bool _is_free;
  76   HRSMtSafeChecker* _mt_safety_checker;
  77 
  78 protected:
  79   // The number of regions in to the set.
  80   uint _length;
  81 
  82   const char* _name;
  83 
  84   bool _verify_in_progress;
  85 
  86   // verify_region() is used to ensure that the contents of a region
  87   // added to / removed from a set are consistent.
  88   void verify_region(HeapRegion* hr) PRODUCT_RETURN;
  89 
  90   // Indicates whether all regions in the set should be humongous or
  91   // not. Only used during verification.




  51 // asserts are compiled in.
  52 #ifndef HEAP_REGION_SET_FORCE_VERIFY
  53 #define HEAP_REGION_SET_FORCE_VERIFY defined(ASSERT)
  54 #endif // HEAP_REGION_SET_FORCE_VERIFY
  55 
  56 class HRSMtSafeChecker : public CHeapObj<mtGC> {
  57 public:
  58   virtual void check() = 0;
  59 };
  60 
  61 class MasterFreeRegionListMtSafeChecker    : public HRSMtSafeChecker { public: void check(); };
  62 class SecondaryFreeRegionListMtSafeChecker : public HRSMtSafeChecker { public: void check(); };
  63 class HumongousRegionSetMtSafeChecker      : public HRSMtSafeChecker { public: void check(); };
  64 class OldRegionSetMtSafeChecker            : public HRSMtSafeChecker { public: void check(); };
  65 
  66 // Base class for all the classes that represent heap region sets. It
  67 // contains the basic attributes that each set needs to maintain
  68 // (e.g., length, region num, used bytes sum) plus any shared
  69 // functionality (e.g., verification).
  70 
  71 class HeapRegionSetBase {
  72   friend class VMStructs;
  73 private:
  74   bool _is_humongous;
  75   bool _is_free;
  76   HRSMtSafeChecker* _mt_safety_checker;
  77 
  78 protected:
  79   // The number of regions in to the set.
  80   uint _length;
  81 
  82   const char* _name;
  83 
  84   bool _verify_in_progress;
  85 
  86   // verify_region() is used to ensure that the contents of a region
  87   // added to / removed from a set are consistent.
  88   void verify_region(HeapRegion* hr) PRODUCT_RETURN;
  89 
  90   // Indicates whether all regions in the set should be humongous or
  91   // not. Only used during verification.


< prev index next >