Mercurial > hg > truffle
comparison src/share/vm/memory/metaspace.hpp @ 12902:bdfbb1fb19ca
8026391: The Metachunk header wastes memory
Reviewed-by: coleenp, jmasa
author | stefank |
---|---|
date | Tue, 15 Oct 2013 14:28:51 +0200 |
parents | 85c1ca43713f |
children | a6177f601c64 |
comparison
equal
deleted
inserted
replaced
12901:f16726924734 | 12902:bdfbb1fb19ca |
---|---|
137 SpaceManager* class_vsm() const { return _class_vsm; } | 137 SpaceManager* class_vsm() const { return _class_vsm; } |
138 | 138 |
139 // Allocate space for metadata of type mdtype. This is space | 139 // Allocate space for metadata of type mdtype. This is space |
140 // within a Metachunk and is used by | 140 // within a Metachunk and is used by |
141 // allocate(ClassLoaderData*, size_t, bool, MetadataType, TRAPS) | 141 // allocate(ClassLoaderData*, size_t, bool, MetadataType, TRAPS) |
142 // which returns a Metablock. | |
143 MetaWord* allocate(size_t word_size, MetadataType mdtype); | 142 MetaWord* allocate(size_t word_size, MetadataType mdtype); |
144 | 143 |
145 // Virtual Space lists for both classes and other metadata | 144 // Virtual Space lists for both classes and other metadata |
146 static VirtualSpaceList* _space_list; | 145 static VirtualSpaceList* _space_list; |
147 static VirtualSpaceList* _class_space_list; | 146 static VirtualSpaceList* _class_space_list; |
215 size_t capacity_words_slow(MetadataType mdtype) const; | 214 size_t capacity_words_slow(MetadataType mdtype) const; |
216 | 215 |
217 size_t used_bytes_slow(MetadataType mdtype) const; | 216 size_t used_bytes_slow(MetadataType mdtype) const; |
218 size_t capacity_bytes_slow(MetadataType mdtype) const; | 217 size_t capacity_bytes_slow(MetadataType mdtype) const; |
219 | 218 |
220 static Metablock* allocate(ClassLoaderData* loader_data, size_t word_size, | 219 static MetaWord* allocate(ClassLoaderData* loader_data, size_t word_size, |
221 bool read_only, MetaspaceObj::Type type, TRAPS); | 220 bool read_only, MetaspaceObj::Type type, TRAPS); |
222 void deallocate(MetaWord* ptr, size_t byte_size, bool is_class); | 221 void deallocate(MetaWord* ptr, size_t byte_size, bool is_class); |
223 | 222 |
224 MetaWord* expand_and_allocate(size_t size, | 223 MetaWord* expand_and_allocate(size_t size, |
225 MetadataType mdtype); | 224 MetadataType mdtype); |
226 | 225 |