125
126 // Returns JNI_OK on success
127 virtual jint initialize();
128
129 // Reserve aligned space for the heap as needed by the contained generations.
130 char* allocate(size_t alignment, ReservedSpace* heap_rs);
131
132 // Does operations required after initialization has been done.
133 void post_initialize();
134
135 // Initialize ("weak") refs processing support
136 virtual void ref_processing_init();
137
138 virtual Name kind() const {
139 return CollectedHeap::GenCollectedHeap;
140 }
141
142 Generation* young_gen() const { return _young_gen; }
143 Generation* old_gen() const { return _old_gen; }
144
145 // The generational collector policy.
146 GenCollectorPolicy* gen_policy() const { return _gen_policy; }
147
148 virtual CollectorPolicy* collector_policy() const { return (CollectorPolicy*) gen_policy(); }
149
150 // Adaptive size policy
151 virtual AdaptiveSizePolicy* size_policy() {
152 return gen_policy()->size_policy();
153 }
154
155 // Return the (conservative) maximum heap alignment
156 static size_t conservative_max_heap_alignment() {
157 return Generation::GenGrain;
158 }
159
160 size_t capacity() const;
161 size_t used() const;
162
163 // Save the "used_region" for both generations.
164 void save_used_regions();
|
125
126 // Returns JNI_OK on success
127 virtual jint initialize();
128
129 // Reserve aligned space for the heap as needed by the contained generations.
130 char* allocate(size_t alignment, ReservedSpace* heap_rs);
131
132 // Does operations required after initialization has been done.
133 void post_initialize();
134
135 // Initialize ("weak") refs processing support
136 virtual void ref_processing_init();
137
138 virtual Name kind() const {
139 return CollectedHeap::GenCollectedHeap;
140 }
141
142 Generation* young_gen() const { return _young_gen; }
143 Generation* old_gen() const { return _old_gen; }
144
145 bool is_young_gen(const Generation* gen) const { return gen == _young_gen; }
146 bool is_old_gen(const Generation* gen) const { return gen == _old_gen; }
147
148 // The generational collector policy.
149 GenCollectorPolicy* gen_policy() const { return _gen_policy; }
150
151 virtual CollectorPolicy* collector_policy() const { return (CollectorPolicy*) gen_policy(); }
152
153 // Adaptive size policy
154 virtual AdaptiveSizePolicy* size_policy() {
155 return gen_policy()->size_policy();
156 }
157
158 // Return the (conservative) maximum heap alignment
159 static size_t conservative_max_heap_alignment() {
160 return Generation::GenGrain;
161 }
162
163 size_t capacity() const;
164 size_t used() const;
165
166 // Save the "used_region" for both generations.
167 void save_used_regions();
|