Mercurial > hg > graal-jvmci-8
diff src/share/vm/gc_implementation/g1/vm_operations_g1.hpp @ 22937:af8f16ac392c
8066771: Refactor VM GC operations caused by allocation failure
Reviewed-by: brutisso, jmasa
author | mlarsson |
---|---|
date | Thu, 09 Apr 2015 15:59:26 +0200 |
parents | fb69749583e8 |
children |
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/vm_operations_g1.hpp Thu Apr 09 15:58:49 2015 +0200 +++ b/src/share/vm/gc_implementation/g1/vm_operations_g1.hpp Thu Apr 09 15:59:26 2015 +0200 @@ -36,10 +36,8 @@ // - VM_G1CollectForAllocation // - VM_G1IncCollectionPause -class VM_G1OperationWithAllocRequest: public VM_GC_Operation { +class VM_G1OperationWithAllocRequest : public VM_CollectForAllocation { protected: - size_t _word_size; - HeapWord* _result; bool _pause_succeeded; AllocationContext_t _allocation_context; @@ -47,9 +45,8 @@ VM_G1OperationWithAllocRequest(uint gc_count_before, size_t word_size, GCCause::Cause gc_cause) - : VM_GC_Operation(gc_count_before, gc_cause), - _word_size(word_size), _result(NULL), _pause_succeeded(false) { } - HeapWord* result() { return _result; } + : VM_CollectForAllocation(word_size, gc_count_before, gc_cause), + _pause_succeeded(false) {} bool pause_succeeded() { return _pause_succeeded; } void set_allocation_context(AllocationContext_t context) { _allocation_context = context; } AllocationContext_t allocation_context() { return _allocation_context; }