src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp

changeset 4489
ef1e11845e18
parent 4469
c73c3f2c5b3b
parent 4488
3c327c2b6782
child 5163
28e53b8db94f
     1.1 --- a/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp	Fri Jan 25 03:03:23 2013 -0800
     1.2 +++ b/src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp	Mon Feb 04 12:01:07 2013 -0800
     1.3 @@ -102,7 +102,7 @@
     1.4    // temporarily disabled).
     1.5    switch (dictionaryChoice) {
     1.6      case FreeBlockDictionary<FreeChunk>::dictionaryBinaryTree:
     1.7 -      _dictionary = new BinaryTreeDictionary<FreeChunk, AdaptiveFreeList>(mr);
     1.8 +      _dictionary = new AFLBinaryTreeDictionary(mr);
     1.9        break;
    1.10      case FreeBlockDictionary<FreeChunk>::dictionarySplayTree:
    1.11      case FreeBlockDictionary<FreeChunk>::dictionarySkipList:
    1.12 @@ -122,7 +122,8 @@
    1.13    // moved to its new location before the klass is moved.
    1.14    // Set the _refillSize for the linear allocation blocks
    1.15    if (!use_adaptive_freelists) {
    1.16 -    FreeChunk* fc = _dictionary->get_chunk(mr.word_size());
    1.17 +    FreeChunk* fc = _dictionary->get_chunk(mr.word_size(),
    1.18 +                                           FreeBlockDictionary<FreeChunk>::atLeast);
    1.19      // The small linAB initially has all the space and will allocate
    1.20      // a chunk of any size.
    1.21      HeapWord* addr = (HeapWord*) fc;
    1.22 @@ -1647,7 +1648,8 @@
    1.23  FreeChunk*
    1.24  CompactibleFreeListSpace::getChunkFromDictionary(size_t size) {
    1.25    assert_locked();
    1.26 -  FreeChunk* fc = _dictionary->get_chunk(size);
    1.27 +  FreeChunk* fc = _dictionary->get_chunk(size,
    1.28 +                                         FreeBlockDictionary<FreeChunk>::atLeast);
    1.29    if (fc == NULL) {
    1.30      return NULL;
    1.31    }
    1.32 @@ -1664,7 +1666,8 @@
    1.33  FreeChunk*
    1.34  CompactibleFreeListSpace::getChunkFromDictionaryExact(size_t size) {
    1.35    assert_locked();
    1.36 -  FreeChunk* fc = _dictionary->get_chunk(size);
    1.37 +  FreeChunk* fc = _dictionary->get_chunk(size,
    1.38 +                                         FreeBlockDictionary<FreeChunk>::atLeast);
    1.39    if (fc == NULL) {
    1.40      return fc;
    1.41    }
    1.42 @@ -1677,7 +1680,8 @@
    1.43    if (fc->size() < size + MinChunkSize) {
    1.44      // Return the chunk to the dictionary and go get a bigger one.
    1.45      returnChunkToDictionary(fc);
    1.46 -    fc = _dictionary->get_chunk(size + MinChunkSize);
    1.47 +    fc = _dictionary->get_chunk(size + MinChunkSize,
    1.48 +                                FreeBlockDictionary<FreeChunk>::atLeast);
    1.49      if (fc == NULL) {
    1.50        return NULL;
    1.51      }

mercurial