23 */
24
25 #ifndef SHARE_VM_GC_G1_CONCURRENTMARKTHREAD_HPP
26 #define SHARE_VM_GC_G1_CONCURRENTMARKTHREAD_HPP
27
28 #include "gc/shared/concurrentGCThread.hpp"
29
30 // The Concurrent Mark GC Thread triggers the parallel CMConcurrentMarkingTasks
31 // as well as handling various marking cleanup.
32
33 class ConcurrentMark;
34 class G1CollectorPolicy;
35
36 class ConcurrentMarkThread: public ConcurrentGCThread {
37 friend class VMStructs;
38
39 double _vtime_start; // Initial virtual time.
40 double _vtime_accum; // Accumulated virtual time.
41
42 double _vtime_mark_accum;
43 void cm_log(bool doit, bool join_sts, const char* fmt, ...) ATTRIBUTE_PRINTF(4, 5);
44
45 public:
46 virtual void run();
47
48 private:
49 ConcurrentMark* _cm;
50
51 enum State {
52 Idle,
53 Started,
54 InProgress
55 };
56
57 volatile State _state;
58
59 void sleepBeforeNextCycle();
60 void delay_to_keep_mmu(G1CollectorPolicy* g1_policy, bool remark);
61
62 void run_service();
63 void stop_service();
|
23 */
24
25 #ifndef SHARE_VM_GC_G1_CONCURRENTMARKTHREAD_HPP
26 #define SHARE_VM_GC_G1_CONCURRENTMARKTHREAD_HPP
27
28 #include "gc/shared/concurrentGCThread.hpp"
29
30 // The Concurrent Mark GC Thread triggers the parallel CMConcurrentMarkingTasks
31 // as well as handling various marking cleanup.
32
33 class ConcurrentMark;
34 class G1CollectorPolicy;
35
36 class ConcurrentMarkThread: public ConcurrentGCThread {
37 friend class VMStructs;
38
39 double _vtime_start; // Initial virtual time.
40 double _vtime_accum; // Accumulated virtual time.
41
42 double _vtime_mark_accum;
43
44 public:
45 virtual void run();
46
47 private:
48 ConcurrentMark* _cm;
49
50 enum State {
51 Idle,
52 Started,
53 InProgress
54 };
55
56 volatile State _state;
57
58 void sleepBeforeNextCycle();
59 void delay_to_keep_mmu(G1CollectorPolicy* g1_policy, bool remark);
60
61 void run_service();
62 void stop_service();
|