43 GCCause::Cause cause) : |
43 GCCause::Cause cause) : |
44 VM_GC_Operation(gc_count_before, cause, full_gc_count_before, true), |
44 VM_GC_Operation(gc_count_before, cause, full_gc_count_before, true), |
45 _gc_succeeded(false) { } |
45 _gc_succeeded(false) { } |
46 virtual VMOp_Type type() const { return VMOp_G1CollectFull; } |
46 virtual VMOp_Type type() const { return VMOp_G1CollectFull; } |
47 virtual void doit(); |
47 virtual void doit(); |
48 bool gc_succeeded() { return _gc_succeeded; } |
48 bool gc_succeeded() const { return _gc_succeeded; } |
|
49 }; |
|
50 |
|
51 class VM_G1TryInitiateConcMark : public VM_GC_Operation { |
|
52 double _target_pause_time_ms; |
|
53 bool _transient_failure; |
|
54 bool _cycle_already_in_progress; |
|
55 bool _gc_succeeded; |
|
56 |
|
57 public: |
|
58 VM_G1TryInitiateConcMark(uint gc_count_before, |
|
59 GCCause::Cause gc_cause, |
|
60 double target_pause_time_ms); |
|
61 virtual VMOp_Type type() const { return VMOp_G1TryInitiateConcMark; } |
|
62 virtual bool doit_prologue(); |
|
63 virtual void doit(); |
|
64 bool transient_failure() const { return _transient_failure; } |
|
65 bool cycle_already_in_progress() const { return _cycle_already_in_progress; } |
|
66 bool gc_succeeded() const { return _gc_succeeded; } |
49 }; |
67 }; |
50 |
68 |
51 class VM_G1CollectForAllocation : public VM_CollectForAllocation { |
69 class VM_G1CollectForAllocation : public VM_CollectForAllocation { |
52 bool _gc_succeeded; |
70 bool _gc_succeeded; |
53 |
|
54 bool _should_initiate_conc_mark; |
|
55 bool _should_retry_gc; |
|
56 double _target_pause_time_ms; |
71 double _target_pause_time_ms; |
57 uint _old_marking_cycles_completed_before; |
|
58 |
72 |
59 public: |
73 public: |
60 VM_G1CollectForAllocation(size_t word_size, |
74 VM_G1CollectForAllocation(size_t word_size, |
61 uint gc_count_before, |
75 uint gc_count_before, |
62 GCCause::Cause gc_cause, |
76 GCCause::Cause gc_cause, |
63 bool should_initiate_conc_mark, |
|
64 double target_pause_time_ms); |
77 double target_pause_time_ms); |
65 virtual VMOp_Type type() const { return VMOp_G1CollectForAllocation; } |
78 virtual VMOp_Type type() const { return VMOp_G1CollectForAllocation; } |
66 virtual bool doit_prologue(); |
|
67 virtual void doit(); |
79 virtual void doit(); |
68 virtual void doit_epilogue(); |
80 bool gc_succeeded() const { return _gc_succeeded; } |
69 bool should_retry_gc() const { return _should_retry_gc; } |
|
70 bool gc_succeeded() { return _gc_succeeded; } |
|
71 }; |
81 }; |
72 |
82 |
73 // Concurrent G1 stop-the-world operations such as remark and cleanup. |
83 // Concurrent G1 stop-the-world operations such as remark and cleanup. |
74 class VM_G1Concurrent : public VM_Operation { |
84 class VM_G1Concurrent : public VM_Operation { |
75 VoidClosure* _cl; |
85 VoidClosure* _cl; |