comparison src/share/vm/memory/metaspace.hpp @ 7435:c71879335291

8005108: NPG: MetaspaceAux::used_in_bytes(), capacity_in_bytes() and reserved_in_bytes() return inconsistent numbers Summary: Reverted the changes to these functions from JDK-8000662 Reviewed-by: brutisso, jmasa
author stefank
date Tue, 18 Dec 2012 10:40:51 +0100
parents 5fafdef522c6
children e51c9860cf66
comparison
equal deleted inserted replaced
7434:32164d89fe9c 7435:c71879335291
154 static size_t free_chunks_total(Metaspace::MetadataType mdtype); 154 static size_t free_chunks_total(Metaspace::MetadataType mdtype);
155 static size_t free_chunks_total_in_bytes(Metaspace::MetadataType mdtype); 155 static size_t free_chunks_total_in_bytes(Metaspace::MetadataType mdtype);
156 156
157 public: 157 public:
158 // Total of space allocated to metadata in all Metaspaces 158 // Total of space allocated to metadata in all Metaspaces
159 static size_t used_in_bytes(); 159 static size_t used_in_bytes() {
160 return used_in_bytes(Metaspace::ClassType) +
161 used_in_bytes(Metaspace::NonClassType);
162 }
160 163
161 // Total of available space in all Metaspaces 164 // Total of available space in all Metaspaces
162 // Total of capacity allocated to all Metaspaces. This includes 165 // Total of capacity allocated to all Metaspaces. This includes
163 // space in Metachunks not yet allocated and in the Metachunk 166 // space in Metachunks not yet allocated and in the Metachunk
164 // freelist. 167 // freelist.
165 static size_t capacity_in_bytes(); 168 static size_t capacity_in_bytes() {
169 return capacity_in_bytes(Metaspace::ClassType) +
170 capacity_in_bytes(Metaspace::NonClassType);
171 }
166 172
167 // Total space reserved in all Metaspaces 173 // Total space reserved in all Metaspaces
168 static size_t reserved_in_bytes(); 174 static size_t reserved_in_bytes() {
175 return reserved_in_bytes(Metaspace::ClassType) +
176 reserved_in_bytes(Metaspace::NonClassType);
177 }
169 178
170 static size_t min_chunk_size(); 179 static size_t min_chunk_size();
171 180
172 // Print change in used metadata. 181 // Print change in used metadata.
173 static void print_metaspace_change(size_t prev_metadata_used); 182 static void print_metaspace_change(size_t prev_metadata_used);