< prev index next >

src/share/vm/gc/g1/g1HotCardCache.cpp

Print this page
rev 10379 : 8151436: Leaner ArrayAllocator

*** 34,44 **** void G1HotCardCache::initialize(G1RegionToSpaceMapper* card_counts_storage) { if (default_use_cache()) { _use_cache = true; _hot_cache_size = (size_t)1 << G1ConcRSLogCacheSize; ! _hot_cache = _hot_cache_memory.allocate(_hot_cache_size); reset_hot_cache_internal(); // For refining the cards in the hot cache in parallel _hot_cache_par_chunk_size = ClaimChunkSize; --- 34,44 ---- void G1HotCardCache::initialize(G1RegionToSpaceMapper* card_counts_storage) { if (default_use_cache()) { _use_cache = true; _hot_cache_size = (size_t)1 << G1ConcRSLogCacheSize; ! _hot_cache = ArrayAllocator<jbyte*, mtGC>::allocate(_hot_cache_size); reset_hot_cache_internal(); // For refining the cards in the hot cache in parallel _hot_cache_par_chunk_size = ClaimChunkSize;
*** 49,59 **** } G1HotCardCache::~G1HotCardCache() { if (default_use_cache()) { assert(_hot_cache != NULL, "Logic"); ! _hot_cache_memory.free(); _hot_cache = NULL; } } jbyte* G1HotCardCache::insert(jbyte* card_ptr) { --- 49,59 ---- } G1HotCardCache::~G1HotCardCache() { if (default_use_cache()) { assert(_hot_cache != NULL, "Logic"); ! ArrayAllocator<jbyte*, mtGC>::free(_hot_cache, _hot_cache_size); _hot_cache = NULL; } } jbyte* G1HotCardCache::insert(jbyte* card_ptr) {
< prev index next >