179 static inline void fill_with_array(HeapWord* start, size_t words, bool zap = true);
180
181 // Fill with a single object (either an int array or a java.lang.Object).
182 static inline void fill_with_object_impl(HeapWord* start, size_t words, bool zap = true);
183
184 virtual void trace_heap(GCWhen::Type when, const GCTracer* tracer);
185
186 // Verification functions
187 virtual void check_for_bad_heap_word_value(HeapWord* addr, size_t size)
188 PRODUCT_RETURN;
189 virtual void check_for_non_bad_heap_word_value(HeapWord* addr, size_t size)
190 PRODUCT_RETURN;
191 debug_only(static void check_for_valid_allocation_state();)
192
193 public:
194 enum Name {
195 None,
196 Serial,
197 Parallel,
198 CMS,
199 G1
200 };
201
202 static inline size_t filler_array_max_size() {
203 return _filler_array_max_size;
204 }
205
206 virtual Name kind() const = 0;
207
208 virtual const char* name() const = 0;
209
210 /**
211 * Returns JNI error code JNI_ENOMEM if memory could not be allocated,
212 * and JNI_OK on success.
213 */
214 virtual jint initialize() = 0;
215
216 // In many heaps, there will be a need to perform some initialization activities
217 // after the Universe is fully formed, but before general heap allocation is allowed.
218 // This is the correct place to place such initialization methods.
219 virtual void post_initialize();
|
179 static inline void fill_with_array(HeapWord* start, size_t words, bool zap = true);
180
181 // Fill with a single object (either an int array or a java.lang.Object).
182 static inline void fill_with_object_impl(HeapWord* start, size_t words, bool zap = true);
183
184 virtual void trace_heap(GCWhen::Type when, const GCTracer* tracer);
185
186 // Verification functions
187 virtual void check_for_bad_heap_word_value(HeapWord* addr, size_t size)
188 PRODUCT_RETURN;
189 virtual void check_for_non_bad_heap_word_value(HeapWord* addr, size_t size)
190 PRODUCT_RETURN;
191 debug_only(static void check_for_valid_allocation_state();)
192
193 public:
194 enum Name {
195 None,
196 Serial,
197 Parallel,
198 CMS,
199 G1,
200 Epsilon,
201 };
202
203 static inline size_t filler_array_max_size() {
204 return _filler_array_max_size;
205 }
206
207 virtual Name kind() const = 0;
208
209 virtual const char* name() const = 0;
210
211 /**
212 * Returns JNI error code JNI_ENOMEM if memory could not be allocated,
213 * and JNI_OK on success.
214 */
215 virtual jint initialize() = 0;
216
217 // In many heaps, there will be a need to perform some initialization activities
218 // after the Universe is fully formed, but before general heap allocation is allowed.
219 // This is the correct place to place such initialization methods.
220 virtual void post_initialize();
|