mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8004895: NPG: JMapPermCore test failure caused by warnings about missing field
Reviewed-by: johnc
This commit is contained in:
parent
ad7544b47c
commit
6f5991fa38
6 changed files with 21 additions and 16 deletions
|
@ -102,7 +102,7 @@ CompactibleFreeListSpace::CompactibleFreeListSpace(BlockOffsetSharedArray* bs,
|
||||||
// temporarily disabled).
|
// temporarily disabled).
|
||||||
switch (dictionaryChoice) {
|
switch (dictionaryChoice) {
|
||||||
case FreeBlockDictionary<FreeChunk>::dictionaryBinaryTree:
|
case FreeBlockDictionary<FreeChunk>::dictionaryBinaryTree:
|
||||||
_dictionary = new BinaryTreeDictionary<FreeChunk, AdaptiveFreeList>(mr);
|
_dictionary = new AFLBinaryTreeDictionary(mr);
|
||||||
break;
|
break;
|
||||||
case FreeBlockDictionary<FreeChunk>::dictionarySplayTree:
|
case FreeBlockDictionary<FreeChunk>::dictionarySplayTree:
|
||||||
case FreeBlockDictionary<FreeChunk>::dictionarySkipList:
|
case FreeBlockDictionary<FreeChunk>::dictionarySkipList:
|
||||||
|
@ -122,7 +122,8 @@ CompactibleFreeListSpace::CompactibleFreeListSpace(BlockOffsetSharedArray* bs,
|
||||||
// moved to its new location before the klass is moved.
|
// moved to its new location before the klass is moved.
|
||||||
// Set the _refillSize for the linear allocation blocks
|
// Set the _refillSize for the linear allocation blocks
|
||||||
if (!use_adaptive_freelists) {
|
if (!use_adaptive_freelists) {
|
||||||
FreeChunk* fc = _dictionary->get_chunk(mr.word_size());
|
FreeChunk* fc = _dictionary->get_chunk(mr.word_size(),
|
||||||
|
FreeBlockDictionary<FreeChunk>::atLeast);
|
||||||
// The small linAB initially has all the space and will allocate
|
// The small linAB initially has all the space and will allocate
|
||||||
// a chunk of any size.
|
// a chunk of any size.
|
||||||
HeapWord* addr = (HeapWord*) fc;
|
HeapWord* addr = (HeapWord*) fc;
|
||||||
|
@ -1647,7 +1648,8 @@ CompactibleFreeListSpace::getChunkFromIndexedFreeListHelper(size_t size,
|
||||||
FreeChunk*
|
FreeChunk*
|
||||||
CompactibleFreeListSpace::getChunkFromDictionary(size_t size) {
|
CompactibleFreeListSpace::getChunkFromDictionary(size_t size) {
|
||||||
assert_locked();
|
assert_locked();
|
||||||
FreeChunk* fc = _dictionary->get_chunk(size);
|
FreeChunk* fc = _dictionary->get_chunk(size,
|
||||||
|
FreeBlockDictionary<FreeChunk>::atLeast);
|
||||||
if (fc == NULL) {
|
if (fc == NULL) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -1664,7 +1666,8 @@ CompactibleFreeListSpace::getChunkFromDictionary(size_t size) {
|
||||||
FreeChunk*
|
FreeChunk*
|
||||||
CompactibleFreeListSpace::getChunkFromDictionaryExact(size_t size) {
|
CompactibleFreeListSpace::getChunkFromDictionaryExact(size_t size) {
|
||||||
assert_locked();
|
assert_locked();
|
||||||
FreeChunk* fc = _dictionary->get_chunk(size);
|
FreeChunk* fc = _dictionary->get_chunk(size,
|
||||||
|
FreeBlockDictionary<FreeChunk>::atLeast);
|
||||||
if (fc == NULL) {
|
if (fc == NULL) {
|
||||||
return fc;
|
return fc;
|
||||||
}
|
}
|
||||||
|
@ -1677,7 +1680,8 @@ CompactibleFreeListSpace::getChunkFromDictionaryExact(size_t size) {
|
||||||
if (fc->size() < size + MinChunkSize) {
|
if (fc->size() < size + MinChunkSize) {
|
||||||
// Return the chunk to the dictionary and go get a bigger one.
|
// Return the chunk to the dictionary and go get a bigger one.
|
||||||
returnChunkToDictionary(fc);
|
returnChunkToDictionary(fc);
|
||||||
fc = _dictionary->get_chunk(size + MinChunkSize);
|
fc = _dictionary->get_chunk(size + MinChunkSize,
|
||||||
|
FreeBlockDictionary<FreeChunk>::atLeast);
|
||||||
if (fc == NULL) {
|
if (fc == NULL) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
|
@ -131,7 +131,7 @@ class CompactibleFreeListSpace: public CompactibleSpace {
|
||||||
LinearAllocBlock _smallLinearAllocBlock;
|
LinearAllocBlock _smallLinearAllocBlock;
|
||||||
|
|
||||||
FreeBlockDictionary<FreeChunk>::DictionaryChoice _dictionaryChoice;
|
FreeBlockDictionary<FreeChunk>::DictionaryChoice _dictionaryChoice;
|
||||||
FreeBlockDictionary<FreeChunk>* _dictionary; // ptr to dictionary for large size blocks
|
AFLBinaryTreeDictionary* _dictionary; // ptr to dictionary for large size blocks
|
||||||
|
|
||||||
AdaptiveFreeList<FreeChunk> _indexedFreeList[IndexSetSize];
|
AdaptiveFreeList<FreeChunk> _indexedFreeList[IndexSetSize];
|
||||||
// indexed array for small size blocks
|
// indexed array for small size blocks
|
||||||
|
|
|
@ -25,8 +25,6 @@
|
||||||
#ifndef SHARE_VM_GC_IMPLEMENTATION_CONCURRENTMARKSWEEP_VMSTRUCTS_CMS_HPP
|
#ifndef SHARE_VM_GC_IMPLEMENTATION_CONCURRENTMARKSWEEP_VMSTRUCTS_CMS_HPP
|
||||||
#define SHARE_VM_GC_IMPLEMENTATION_CONCURRENTMARKSWEEP_VMSTRUCTS_CMS_HPP
|
#define SHARE_VM_GC_IMPLEMENTATION_CONCURRENTMARKSWEEP_VMSTRUCTS_CMS_HPP
|
||||||
|
|
||||||
typedef BinaryTreeDictionary<FreeChunk, AdaptiveFreeList> AFLBinaryTreeDictionary;
|
|
||||||
|
|
||||||
#define VM_STRUCTS_CMS(nonstatic_field, \
|
#define VM_STRUCTS_CMS(nonstatic_field, \
|
||||||
volatile_nonstatic_field, \
|
volatile_nonstatic_field, \
|
||||||
static_field) \
|
static_field) \
|
||||||
|
@ -42,6 +40,7 @@ typedef BinaryTreeDictionary<FreeChunk, AdaptiveFreeList> AFLBinaryTreeDictionar
|
||||||
static_field(ConcurrentMarkSweepThread, _collector, CMSCollector*) \
|
static_field(ConcurrentMarkSweepThread, _collector, CMSCollector*) \
|
||||||
nonstatic_field(LinearAllocBlock, _word_size, size_t) \
|
nonstatic_field(LinearAllocBlock, _word_size, size_t) \
|
||||||
nonstatic_field(AFLBinaryTreeDictionary, _total_size, size_t) \
|
nonstatic_field(AFLBinaryTreeDictionary, _total_size, size_t) \
|
||||||
|
nonstatic_field(CompactibleFreeListSpace, _dictionary, AFLBinaryTreeDictionary*) \
|
||||||
nonstatic_field(CompactibleFreeListSpace, _indexedFreeList[0], FreeList<FreeChunk>) \
|
nonstatic_field(CompactibleFreeListSpace, _indexedFreeList[0], FreeList<FreeChunk>) \
|
||||||
nonstatic_field(CompactibleFreeListSpace, _smallLinearAllocBlock, LinearAllocBlock)
|
nonstatic_field(CompactibleFreeListSpace, _smallLinearAllocBlock, LinearAllocBlock)
|
||||||
|
|
||||||
|
@ -62,10 +61,9 @@ typedef BinaryTreeDictionary<FreeChunk, AdaptiveFreeList> AFLBinaryTreeDictionar
|
||||||
declare_toplevel_type(SurrogateLockerThread*) \
|
declare_toplevel_type(SurrogateLockerThread*) \
|
||||||
declare_toplevel_type(CompactibleFreeListSpace*) \
|
declare_toplevel_type(CompactibleFreeListSpace*) \
|
||||||
declare_toplevel_type(CMSCollector*) \
|
declare_toplevel_type(CMSCollector*) \
|
||||||
declare_toplevel_type(AFLBinaryTreeDictionary*) \
|
declare_toplevel_type(AFLBinaryTreeDictionary) \
|
||||||
declare_toplevel_type(LinearAllocBlock) \
|
declare_toplevel_type(LinearAllocBlock) \
|
||||||
declare_toplevel_type(FreeBlockDictionary<FreeChunk>) \
|
declare_toplevel_type(FreeBlockDictionary<FreeChunk>)
|
||||||
declare_type(AFLBinaryTreeDictionary, FreeBlockDictionary<FreeChunk>)
|
|
||||||
|
|
||||||
#define VM_INT_CONSTANTS_CMS(declare_constant) \
|
#define VM_INT_CONSTANTS_CMS(declare_constant) \
|
||||||
declare_constant(Generation::ConcurrentMarkSweep) \
|
declare_constant(Generation::ConcurrentMarkSweep) \
|
||||||
|
|
|
@ -873,7 +873,7 @@ void BinaryTreeDictionary<Chunk_t, FreeList_t>::dict_census_update(size_t size,
|
||||||
|
|
||||||
#ifndef SERIALGC
|
#ifndef SERIALGC
|
||||||
template <>
|
template <>
|
||||||
void BinaryTreeDictionary<FreeChunk, AdaptiveFreeList>::dict_census_update(size_t size, bool split, bool birth){
|
void AFLBinaryTreeDictionary::dict_census_update(size_t size, bool split, bool birth){
|
||||||
TreeList<FreeChunk, AdaptiveFreeList>* nd = find_list(size);
|
TreeList<FreeChunk, AdaptiveFreeList>* nd = find_list(size);
|
||||||
if (nd) {
|
if (nd) {
|
||||||
if (split) {
|
if (split) {
|
||||||
|
@ -911,7 +911,7 @@ bool BinaryTreeDictionary<Chunk_t, FreeList_t>::coal_dict_over_populated(size_t
|
||||||
|
|
||||||
#ifndef SERIALGC
|
#ifndef SERIALGC
|
||||||
template <>
|
template <>
|
||||||
bool BinaryTreeDictionary<FreeChunk, AdaptiveFreeList>::coal_dict_over_populated(size_t size) {
|
bool AFLBinaryTreeDictionary::coal_dict_over_populated(size_t size) {
|
||||||
if (FLSAlwaysCoalesceLarge) return true;
|
if (FLSAlwaysCoalesceLarge) return true;
|
||||||
|
|
||||||
TreeList<FreeChunk, AdaptiveFreeList>* list_of_size = find_list(size);
|
TreeList<FreeChunk, AdaptiveFreeList>* list_of_size = find_list(size);
|
||||||
|
@ -1288,7 +1288,7 @@ void BinaryTreeDictionary<Chunk_t, FreeList_t>::print_dict_census(void) const {
|
||||||
|
|
||||||
#ifndef SERIALGC
|
#ifndef SERIALGC
|
||||||
template <>
|
template <>
|
||||||
void BinaryTreeDictionary<FreeChunk, AdaptiveFreeList>::print_dict_census(void) const {
|
void AFLBinaryTreeDictionary::print_dict_census(void) const {
|
||||||
|
|
||||||
gclog_or_tty->print("\nBinaryTree\n");
|
gclog_or_tty->print("\nBinaryTree\n");
|
||||||
AdaptiveFreeList<FreeChunk>::print_labels_on(gclog_or_tty, "size");
|
AdaptiveFreeList<FreeChunk>::print_labels_on(gclog_or_tty, "size");
|
||||||
|
|
|
@ -43,6 +43,10 @@ template <class Chunk_t, template <class> class FreeList_t> class AscendTreeCens
|
||||||
template <class Chunk_t, template <class> class FreeList_t> class DescendTreeCensusClosure;
|
template <class Chunk_t, template <class> class FreeList_t> class DescendTreeCensusClosure;
|
||||||
template <class Chunk_t, template <class> class FreeList_t> class DescendTreeSearchClosure;
|
template <class Chunk_t, template <class> class FreeList_t> class DescendTreeSearchClosure;
|
||||||
|
|
||||||
|
class FreeChunk;
|
||||||
|
template <class> class AdaptiveFreeList;
|
||||||
|
typedef BinaryTreeDictionary<FreeChunk, AdaptiveFreeList> AFLBinaryTreeDictionary;
|
||||||
|
|
||||||
template <class Chunk_t, template <class> class FreeList_t>
|
template <class Chunk_t, template <class> class FreeList_t>
|
||||||
class TreeList : public FreeList_t<Chunk_t> {
|
class TreeList : public FreeList_t<Chunk_t> {
|
||||||
friend class TreeChunk<Chunk_t, FreeList_t>;
|
friend class TreeChunk<Chunk_t, FreeList_t>;
|
||||||
|
|
|
@ -2087,8 +2087,7 @@ typedef BinaryTreeDictionary<Metablock, FreeList> MetablockTreeDictionary;
|
||||||
declare_toplevel_type(FreeBlockDictionary<Metablock>*) \
|
declare_toplevel_type(FreeBlockDictionary<Metablock>*) \
|
||||||
declare_toplevel_type(FreeList<Metablock>*) \
|
declare_toplevel_type(FreeList<Metablock>*) \
|
||||||
declare_toplevel_type(FreeList<Metablock>) \
|
declare_toplevel_type(FreeList<Metablock>) \
|
||||||
declare_toplevel_type(MetablockTreeDictionary*) \
|
declare_type(MetablockTreeDictionary, FreeBlockDictionary<Metablock>)
|
||||||
declare_type(MetablockTreeDictionary, FreeBlockDictionary<Metablock>)
|
|
||||||
|
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue