Mercurial > hg > graal-jvmci-8
comparison src/share/vm/oops/cpCacheKlass.cpp @ 3892:baf763f388e6
7059037: Use BIS for zeroing on T4
Summary: Use BIS for zeroing new allocated big (2Kb and more) objects and arrays.
Reviewed-by: never, twisti, ysr
author | kvn |
---|---|
date | Fri, 26 Aug 2011 08:52:22 -0700 |
parents | c7f3d0b4570f |
children |
comparison
equal
deleted
inserted
replaced
3891:ac8738449b6f | 3892:baf763f388e6 |
---|---|
61 // size(), before setting its klass word further below. | 61 // size(), before setting its klass word further below. |
62 // constantPoolCacheOop cache = (constantPoolCacheOop) | 62 // constantPoolCacheOop cache = (constantPoolCacheOop) |
63 // CollectedHeap::permanent_obj_allocate(klass, size, CHECK_NULL); | 63 // CollectedHeap::permanent_obj_allocate(klass, size, CHECK_NULL); |
64 | 64 |
65 oop obj = CollectedHeap::permanent_obj_allocate_no_klass_install(klass, size, CHECK_NULL); | 65 oop obj = CollectedHeap::permanent_obj_allocate_no_klass_install(klass, size, CHECK_NULL); |
66 NOT_PRODUCT(Universe::heap()->check_for_bad_heap_word_value((HeapWord*) obj, | 66 #ifndef PRODUCT |
67 size)); | 67 const size_t hs = oopDesc::header_size(); |
68 Universe::heap()->check_for_bad_heap_word_value(((HeapWord*) obj)+hs, size-hs); | |
69 #endif | |
68 constantPoolCacheOop cache = (constantPoolCacheOop) obj; | 70 constantPoolCacheOop cache = (constantPoolCacheOop) obj; |
69 assert(!UseConcMarkSweepGC || obj->klass_or_null() == NULL, | 71 assert(!UseConcMarkSweepGC || obj->klass_or_null() == NULL, |
70 "klass should be NULL here when using CMS"); | 72 "klass should be NULL here when using CMS"); |
71 cache->set_length(length); // should become visible before klass is set below. | 73 cache->set_length(length); // should become visible before klass is set below. |
72 cache->set_constant_pool(NULL); | 74 cache->set_constant_pool(NULL); |