< prev index next >

src/hotspot/share/gc/g1/g1CollectedHeap.cpp

Print this page
rev 50095 : [mq]: allocations-rt.patch

*** 60,69 **** --- 60,70 ---- #include "gc/g1/heapRegion.inline.hpp" #include "gc/g1/heapRegionRemSet.hpp" #include "gc/g1/heapRegionSet.inline.hpp" #include "gc/g1/vm_operations_g1.hpp" #include "gc/shared/adaptiveSizePolicy.hpp" + #include "gc/shared/collectedHeap.inline.hpp" #include "gc/shared/gcHeapSummary.hpp" #include "gc/shared/gcId.hpp" #include "gc/shared/gcLocker.hpp" #include "gc/shared/gcTimer.hpp" #include "gc/shared/gcTrace.hpp"
*** 390,403 **** return attempt_allocation(word_size); } HeapWord* ! G1CollectedHeap::mem_allocate(size_t word_size, bool* gc_overhead_limit_was_exceeded) { assert_heap_not_locked_and_not_at_safepoint(); if (is_humongous(word_size)) { return attempt_allocation_humongous(word_size); } return attempt_allocation(word_size); } --- 391,408 ---- return attempt_allocation(word_size); } HeapWord* ! G1CollectedHeap::mem_allocate(size_t word_size, Klass* klass, Thread* thread, bool* gc_overhead_limit_was_exceeded) { assert_heap_not_locked_and_not_at_safepoint(); + HeapWord* obj = allocate_from_tlab(klass, thread, word_size); + if (obj != NULL) { + return obj; + } if (is_humongous(word_size)) { return attempt_allocation_humongous(word_size); } return attempt_allocation(word_size); }
< prev index next >