< prev index next >

src/share/vm/gc/shared/cardGeneration.hpp

Print this page




  35 
  36 class CardGeneration: public Generation {
  37   friend class VMStructs;
  38  protected:
  39   // This is shared with other generations.
  40   GenRemSet* _rs;
  41   // This is local to this generation.
  42   BlockOffsetSharedArray* _bts;
  43 
  44   // Current shrinking effect: this damps shrinking when the heap gets empty.
  45   size_t _shrink_factor;
  46 
  47   size_t _min_heap_delta_bytes;   // Minimum amount to expand.
  48 
  49   // Some statistics from before gc started.
  50   // These are gathered in the gc_prologue (and should_collect)
  51   // to control growing/shrinking policy in spite of promotions.
  52   size_t _capacity_at_prologue;
  53   size_t _used_at_prologue;
  54 
  55   CardGeneration(ReservedSpace rs, size_t initial_byte_size, int level,
  56                  GenRemSet* remset);
  57 
  58   virtual void assert_correct_size_change_locking() = 0;
  59 
  60   virtual CompactibleSpace* space() const = 0;
  61 
  62  public:
  63 
  64   // Attempt to expand the generation by "bytes".  Expand by at a
  65   // minimum "expand_bytes".  Return true if some amount (not
  66   // necessarily the full "bytes") was done.
  67   virtual bool expand(size_t bytes, size_t expand_bytes);
  68 
  69   // Shrink generation with specified size
  70   virtual void shrink(size_t bytes);
  71 
  72   virtual void compute_new_size();
  73 
  74   virtual void clear_remembered_set();
  75 
  76   virtual void invalidate_remembered_set();




  35 
  36 class CardGeneration: public Generation {
  37   friend class VMStructs;
  38  protected:
  39   // This is shared with other generations.
  40   GenRemSet* _rs;
  41   // This is local to this generation.
  42   BlockOffsetSharedArray* _bts;
  43 
  44   // Current shrinking effect: this damps shrinking when the heap gets empty.
  45   size_t _shrink_factor;
  46 
  47   size_t _min_heap_delta_bytes;   // Minimum amount to expand.
  48 
  49   // Some statistics from before gc started.
  50   // These are gathered in the gc_prologue (and should_collect)
  51   // to control growing/shrinking policy in spite of promotions.
  52   size_t _capacity_at_prologue;
  53   size_t _used_at_prologue;
  54 
  55   CardGeneration(ReservedSpace rs, size_t initial_byte_size, GenRemSet* remset);

  56 
  57   virtual void assert_correct_size_change_locking() = 0;
  58 
  59   virtual CompactibleSpace* space() const = 0;
  60 
  61  public:
  62 
  63   // Attempt to expand the generation by "bytes".  Expand by at a
  64   // minimum "expand_bytes".  Return true if some amount (not
  65   // necessarily the full "bytes") was done.
  66   virtual bool expand(size_t bytes, size_t expand_bytes);
  67 
  68   // Shrink generation with specified size
  69   virtual void shrink(size_t bytes);
  70 
  71   virtual void compute_new_size();
  72 
  73   virtual void clear_remembered_set();
  74 
  75   virtual void invalidate_remembered_set();


< prev index next >