8003553: NPG: metaspace objects should be zeroed in constructors

Zero metadata in constructors, not in allocation (and some in constructors)

Reviewed-by: jmasa, sspitsyn
This commit is contained in:
Coleen Phillimore 2013-03-08 11:47:57 -05:00
parent 4cdcd6dc13
commit addd95f165
13 changed files with 111 additions and 97 deletions

View file

@ -84,15 +84,13 @@ void Rewriter::make_constant_pool_cache(TRAPS) {
const int length = _cp_cache_map.length();
ClassLoaderData* loader_data = _pool->pool_holder()->class_loader_data();
ConstantPoolCache* cache =
ConstantPoolCache::allocate(loader_data, length, CHECK);
ConstantPoolCache::allocate(loader_data, length, _cp_cache_map,
_invokedynamic_references_map, CHECK);
// initialize object cache in constant pool
_pool->initialize_resolved_references(loader_data, _resolved_references_map,
_resolved_reference_limit,
CHECK);
No_Safepoint_Verifier nsv;
cache->initialize(_cp_cache_map, _invokedynamic_references_map);
_pool->set_cache(cache);
cache->set_constant_pool(_pool());
}