< prev index next >
src/hotspot/share/gc/shared/collectedHeap.hpp
Print this page
rev 50390 : [mq]: JDK-8202776.patch
@@ -139,12 +139,19 @@
// Reinitialize tlabs before resuming mutators.
virtual void resize_all_tlabs();
// Allocate from the current thread's TLAB, with broken-out slow path.
- inline static HeapWord* allocate_from_tlab(Klass* klass, Thread* thread, size_t size);
- static HeapWord* allocate_from_tlab_slow(Klass* klass, Thread* thread, size_t size);
+ inline static HeapWord* allocate_from_tlab(Klass* klass, size_t size, TRAPS);
+ static HeapWord* allocate_from_tlab_slow(Klass* klass, size_t size, TRAPS);
+
+ // Raw memory allocation facilities
+ // The obj and array allocate methods are covers for these methods.
+ // mem_allocate() should never be
+ // called to allocate TLABs, only individual objects.
+ virtual HeapWord* mem_allocate(size_t size,
+ bool* gc_overhead_limit_was_exceeded) = 0;
// Allocate an uninitialized block of the given size, or returns NULL if
// this is impossible.
inline static HeapWord* common_mem_allocate_noinit(Klass* klass, size_t size, TRAPS);
@@ -307,16 +314,16 @@
inline static oop obj_allocate(Klass* klass, int size, TRAPS);
inline static oop array_allocate(Klass* klass, int size, int length, TRAPS);
inline static oop array_allocate_nozero(Klass* klass, int size, int length, TRAPS);
inline static oop class_allocate(Klass* klass, int size, TRAPS);
- // Raw memory allocation facilities
- // The obj and array allocate methods are covers for these methods.
- // mem_allocate() should never be
- // called to allocate TLABs, only individual objects.
- virtual HeapWord* mem_allocate(size_t size,
- bool* gc_overhead_limit_was_exceeded) = 0;
+ // Raw memory allocation. This may or may not use TLAB allocations to satisfy the
+ // allocation. A GC implementation may override this function to satisfy the allocation
+ // in any way. But the default is to try a TLAB allocation, and otherwise perform
+ // mem_allocate.
+ virtual HeapWord* obj_allocate_raw(Klass* klass, size_t size,
+ bool* gc_overhead_limit_was_exceeded, TRAPS);
// Utilities for turning raw memory into filler objects.
//
// min_fill_size() is the smallest region that can be filled.
// fill_with_objects() can fill arbitrary-sized regions of the heap using
< prev index next >