1100 // In support of MinChunkSize being larger than min object size 1101 const double _dilatation_factor; 1102 1103 enum CollectionTypes { 1104 Concurrent_collection_type = 0, 1105 MS_foreground_collection_type = 1, 1106 MSC_foreground_collection_type = 2, 1107 Unknown_collection_type = 3 1108 }; 1109 1110 CollectionTypes _debug_collection_type; 1111 1112 // True if a compacting collection was done. 1113 bool _did_compact; 1114 bool did_compact() { return _did_compact; } 1115 1116 // Fraction of current occupancy at which to start a CMS collection which 1117 // will collect this generation (at least). 1118 double _initiating_occupancy; 1119 1120 protected: 1121 // Shrink generation by specified size (returns false if unable to shrink) 1122 void shrink_free_list_by(size_t bytes); 1123 1124 // Update statistics for GC 1125 virtual void update_gc_stats(int level, bool full); 1126 1127 // Maximum available space in the generation (including uncommitted) 1128 // space. 1129 size_t max_available() const; 1130 1131 // getter and initializer for _initiating_occupancy field. 1132 double initiating_occupancy() const { return _initiating_occupancy; } 1133 void init_initiating_occupancy(intx io, uintx tr); 1134 1135 public: 1136 ConcurrentMarkSweepGeneration(ReservedSpace rs, size_t initial_byte_size, 1137 int level, CardTableRS* ct, 1138 bool use_adaptive_freelists, 1139 FreeBlockDictionary<FreeChunk>::DictionaryChoice); | 1100 // In support of MinChunkSize being larger than min object size 1101 const double _dilatation_factor; 1102 1103 enum CollectionTypes { 1104 Concurrent_collection_type = 0, 1105 MS_foreground_collection_type = 1, 1106 MSC_foreground_collection_type = 2, 1107 Unknown_collection_type = 3 1108 }; 1109 1110 CollectionTypes _debug_collection_type; 1111 1112 // True if a compacting collection was done. 1113 bool _did_compact; 1114 bool did_compact() { return _did_compact; } 1115 1116 // Fraction of current occupancy at which to start a CMS collection which 1117 // will collect this generation (at least). 1118 double _initiating_occupancy; 1119 1120 // Set to true, if another GC thread already had a promotion failure. 1121 bool _has_promotion_failed; 1122 1123 // Support for CMSFastPromotionFailure 1124 bool has_promotion_failed() { return _has_promotion_failed; } 1125 void set_promotion_failed() { _has_promotion_failed = true; } 1126 void reset_promotion_failed() { _has_promotion_failed = false; } 1127 1128 protected: 1129 // Shrink generation by specified size (returns false if unable to shrink) 1130 void shrink_free_list_by(size_t bytes); 1131 1132 // Update statistics for GC 1133 virtual void update_gc_stats(int level, bool full); 1134 1135 // Maximum available space in the generation (including uncommitted) 1136 // space. 1137 size_t max_available() const; 1138 1139 // getter and initializer for _initiating_occupancy field. 1140 double initiating_occupancy() const { return _initiating_occupancy; } 1141 void init_initiating_occupancy(intx io, uintx tr); 1142 1143 public: 1144 ConcurrentMarkSweepGeneration(ReservedSpace rs, size_t initial_byte_size, 1145 int level, CardTableRS* ct, 1146 bool use_adaptive_freelists, 1147 FreeBlockDictionary<FreeChunk>::DictionaryChoice); |