equal
deleted
inserted
replaced
73 class CompactibleFreeListSpace: public CompactibleSpace { |
73 class CompactibleFreeListSpace: public CompactibleSpace { |
74 friend class VMStructs; |
74 friend class VMStructs; |
75 friend class ConcurrentMarkSweepGeneration; |
75 friend class ConcurrentMarkSweepGeneration; |
76 friend class CMSCollector; |
76 friend class CMSCollector; |
77 // Local alloc buffer for promotion into this space. |
77 // Local alloc buffer for promotion into this space. |
78 friend class CFLS_LAB; |
78 friend class CompactibleFreeListSpaceLAB; |
79 // Allow scan_and_* functions to call (private) overrides of the auxiliary functions on this class |
79 // Allow scan_and_* functions to call (private) overrides of the auxiliary functions on this class |
80 template <typename SpaceType> |
80 template <typename SpaceType> |
81 friend void CompactibleSpace::scan_and_adjust_pointers(SpaceType* space); |
81 friend void CompactibleSpace::scan_and_adjust_pointers(SpaceType* space); |
82 template <typename SpaceType> |
82 template <typename SpaceType> |
83 friend void CompactibleSpace::scan_and_compact(SpaceType* space); |
83 friend void CompactibleSpace::scan_and_compact(SpaceType* space); |
660 double flsFrag() const; |
660 double flsFrag() const; |
661 }; |
661 }; |
662 |
662 |
663 // A parallel-GC-thread-local allocation buffer for allocation into a |
663 // A parallel-GC-thread-local allocation buffer for allocation into a |
664 // CompactibleFreeListSpace. |
664 // CompactibleFreeListSpace. |
665 class CFLS_LAB : public CHeapObj<mtGC> { |
665 class CompactibleFreeListSpaceLAB : public CHeapObj<mtGC> { |
666 // The space that this buffer allocates into. |
666 // The space that this buffer allocates into. |
667 CompactibleFreeListSpace* _cfls; |
667 CompactibleFreeListSpace* _cfls; |
668 |
668 |
669 // Our local free lists. |
669 // Our local free lists. |
670 AdaptiveFreeList<FreeChunk> _indexedFreeList[CompactibleFreeListSpace::IndexSetSize]; |
670 AdaptiveFreeList<FreeChunk> _indexedFreeList[CompactibleFreeListSpace::IndexSetSize]; |
684 |
684 |
685 public: |
685 public: |
686 static const int _default_dynamic_old_plab_size = 16; |
686 static const int _default_dynamic_old_plab_size = 16; |
687 static const int _default_static_old_plab_size = 50; |
687 static const int _default_static_old_plab_size = 50; |
688 |
688 |
689 CFLS_LAB(CompactibleFreeListSpace* cfls); |
689 CompactibleFreeListSpaceLAB(CompactibleFreeListSpace* cfls); |
690 |
690 |
691 // Allocate and return a block of the given size, or else return NULL. |
691 // Allocate and return a block of the given size, or else return NULL. |
692 HeapWord* alloc(size_t word_sz); |
692 HeapWord* alloc(size_t word_sz); |
693 |
693 |
694 // Return any unused portions of the buffer to the global pool. |
694 // Return any unused portions of the buffer to the global pool. |