src/hotspot/share/gc/shared/collectedHeap.hpp
branchepsilon-gc-branch
changeset 56675 483d23cdc9e5
parent 56578 e8414c8ead61
parent 50414 7efd1291e962
child 56719 a846e7bbcdfa
equal deleted inserted replaced
56671:c559de946c7d 56675:483d23cdc9e5
   139 
   139 
   140   // Reinitialize tlabs before resuming mutators.
   140   // Reinitialize tlabs before resuming mutators.
   141   virtual void resize_all_tlabs();
   141   virtual void resize_all_tlabs();
   142 
   142 
   143   // Allocate from the current thread's TLAB, with broken-out slow path.
   143   // Allocate from the current thread's TLAB, with broken-out slow path.
   144   inline static HeapWord* allocate_from_tlab(Klass* klass, Thread* thread, size_t size);
   144   inline static HeapWord* allocate_from_tlab(Klass* klass, size_t size, TRAPS);
   145   static HeapWord* allocate_from_tlab_slow(Klass* klass, Thread* thread, size_t size);
   145   static HeapWord* allocate_from_tlab_slow(Klass* klass, size_t size, TRAPS);
       
   146 
       
   147   // Raw memory allocation facilities
       
   148   // The obj and array allocate methods are covers for these methods.
       
   149   // mem_allocate() should never be
       
   150   // called to allocate TLABs, only individual objects.
       
   151   virtual HeapWord* mem_allocate(size_t size,
       
   152                                  bool* gc_overhead_limit_was_exceeded) = 0;
   146 
   153 
   147   // Allocate an uninitialized block of the given size, or returns NULL if
   154   // Allocate an uninitialized block of the given size, or returns NULL if
   148   // this is impossible.
   155   // this is impossible.
   149   inline static HeapWord* common_mem_allocate_noinit(Klass* klass, size_t size, TRAPS);
   156   inline static HeapWord* common_mem_allocate_noinit(Klass* klass, size_t size, TRAPS);
   150 
   157 
   308   inline static oop obj_allocate(Klass* klass, int size, TRAPS);
   315   inline static oop obj_allocate(Klass* klass, int size, TRAPS);
   309   inline static oop array_allocate(Klass* klass, int size, int length, TRAPS);
   316   inline static oop array_allocate(Klass* klass, int size, int length, TRAPS);
   310   inline static oop array_allocate_nozero(Klass* klass, int size, int length, TRAPS);
   317   inline static oop array_allocate_nozero(Klass* klass, int size, int length, TRAPS);
   311   inline static oop class_allocate(Klass* klass, int size, TRAPS);
   318   inline static oop class_allocate(Klass* klass, int size, TRAPS);
   312 
   319 
   313   // Raw memory allocation facilities
   320   // Raw memory allocation. This may or may not use TLAB allocations to satisfy the
   314   // The obj and array allocate methods are covers for these methods.
   321   // allocation. A GC implementation may override this function to satisfy the allocation
   315   // mem_allocate() should never be
   322   // in any way. But the default is to try a TLAB allocation, and otherwise perform
   316   // called to allocate TLABs, only individual objects.
   323   // mem_allocate.
   317   virtual HeapWord* mem_allocate(size_t size,
   324   virtual HeapWord* obj_allocate_raw(Klass* klass, size_t size,
   318                                  bool* gc_overhead_limit_was_exceeded) = 0;
   325                                      bool* gc_overhead_limit_was_exceeded, TRAPS);
   319 
   326 
   320   // Utilities for turning raw memory into filler objects.
   327   // Utilities for turning raw memory into filler objects.
   321   //
   328   //
   322   // min_fill_size() is the smallest region that can be filled.
   329   // min_fill_size() is the smallest region that can be filled.
   323   // fill_with_objects() can fill arbitrary-sized regions of the heap using
   330   // fill_with_objects() can fill arbitrary-sized regions of the heap using