< prev index next >

src/share/vm/gc/shenandoah/vm_operations_shenandoah.hpp

Print this page
rev 13387 : [mq]: parallel_sp_cleaning.patch


  25 #define SHARE_VM_GC_SHENANDOAH_VM_OPERATIONS_SHENANDOAH_HPP
  26 
  27 #include "gc/shenandoah/shenandoahConcurrentMark.hpp"
  28 #include "gc/shared/vmGCOperations.hpp"
  29 
  30 // VM_operations for the Shenandoah Collector.
  31 //
  32 // VM_ShenandoahOperation
  33 //   - VM_ShenandoahInitMark: initiate concurrent marking
  34 //   - VM_ShenandoahReferenceOperation:
  35 //       - VM_ShenandoahFinalMarkStartEvac: finish up concurrent marking, and start evacuation
  36 //       - VM_ShenandoahInitUpdateRefs: initiate update references
  37 //       - VM_ShenandoahFinalUpdateRefs: finish up update references
  38 //       - VM_ShenandoahFullGC: do full GC
  39 //       - VM_ShenandoahPartialGC: do partial GC
  40 
  41 class VM_ShenandoahOperation : public VM_Operation {
  42 protected:
  43   uint         _gc_id;
  44 public:
  45   VM_ShenandoahOperation() : _gc_id(GCId::current()) {};



  46 };
  47 
  48 class VM_ShenandoahReferenceOperation : public VM_ShenandoahOperation {
  49 public:
  50   VM_ShenandoahReferenceOperation() : VM_ShenandoahOperation() {};
  51   bool doit_prologue();
  52   void doit_epilogue();
  53 };
  54 
  55 class VM_ShenandoahInitMark: public VM_ShenandoahOperation {
  56 public:
  57   VM_ShenandoahInitMark() : VM_ShenandoahOperation() {};
  58   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahInitMark; }
  59   const char* name()             const { return "Shenandoah Init Marking"; }
  60   virtual void doit();
  61 };
  62 
  63 class VM_ShenandoahFinalMarkStartEvac: public VM_ShenandoahReferenceOperation {
  64 public:
  65   VM_ShenandoahFinalMarkStartEvac() : VM_ShenandoahReferenceOperation() {};


  75   VM_ShenandoahFullGC(GCCause::Cause gc_cause) : VM_ShenandoahReferenceOperation(), _gc_cause(gc_cause) {};
  76   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahFullGC; }
  77   const char* name()             const { return "Shenandoah Full GC"; }
  78   virtual void doit();
  79 };
  80 
  81 class VM_ShenandoahPartialGC: public VM_ShenandoahOperation {
  82 public:
  83   VM_ShenandoahPartialGC() : VM_ShenandoahOperation() {};
  84   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahPartialGC; }
  85   const char* name()             const { return "Shenandoah Partial Collection"; }
  86   virtual void doit();
  87 };
  88 
  89 class VM_ShenandoahInitUpdateRefs: public VM_ShenandoahOperation {
  90 public:
  91   VM_ShenandoahInitUpdateRefs() : VM_ShenandoahOperation() {};
  92   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahInitUpdateRefs; }
  93   const char* name()             const { return "Shenandoah Init Update References"; }
  94   virtual void doit();



  95 };
  96 
  97 class VM_ShenandoahFinalUpdateRefs: public VM_ShenandoahOperation {
  98 public:
  99   VM_ShenandoahFinalUpdateRefs() : VM_ShenandoahOperation() {};
 100   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahFinalUpdateRefs; }
 101   const char* name()             const { return "Shenandoah Final Update References"; }
 102   virtual void doit();
 103 };
 104 
 105 class VM_ShenandoahVerifyHeapAfterEvacuation: public VM_ShenandoahOperation {
 106 public:
 107   VM_ShenandoahVerifyHeapAfterEvacuation() : VM_ShenandoahOperation() {};
 108   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahVerifyHeapAfterEvacuation; }
 109   const char* name()             const { return "Shenandoah verify heap after evacuation"; }
 110   virtual void doit();



 111 };
 112 
 113 #endif //SHARE_VM_GC_SHENANDOAH_VM_OPERATIONS_SHENANDOAH_HPP


  25 #define SHARE_VM_GC_SHENANDOAH_VM_OPERATIONS_SHENANDOAH_HPP
  26 
  27 #include "gc/shenandoah/shenandoahConcurrentMark.hpp"
  28 #include "gc/shared/vmGCOperations.hpp"
  29 
  30 // VM_operations for the Shenandoah Collector.
  31 //
  32 // VM_ShenandoahOperation
  33 //   - VM_ShenandoahInitMark: initiate concurrent marking
  34 //   - VM_ShenandoahReferenceOperation:
  35 //       - VM_ShenandoahFinalMarkStartEvac: finish up concurrent marking, and start evacuation
  36 //       - VM_ShenandoahInitUpdateRefs: initiate update references
  37 //       - VM_ShenandoahFinalUpdateRefs: finish up update references
  38 //       - VM_ShenandoahFullGC: do full GC
  39 //       - VM_ShenandoahPartialGC: do partial GC
  40 
  41 class VM_ShenandoahOperation : public VM_Operation {
  42 protected:
  43   uint         _gc_id;
  44 public:
  45   bool _safepoint_cleanup_done;
  46   VM_ShenandoahOperation() : _gc_id(GCId::current()), _safepoint_cleanup_done(false) {};
  47   virtual bool deflates_idle_monitors() { return ShenandoahMergeSafepointCleanup && ! _safepoint_cleanup_done; }
  48   virtual bool marks_nmethods() { return ShenandoahMergeSafepointCleanup && ! _safepoint_cleanup_done; }
  49 };
  50 
  51 class VM_ShenandoahReferenceOperation : public VM_ShenandoahOperation {
  52 public:
  53   VM_ShenandoahReferenceOperation() : VM_ShenandoahOperation() {};
  54   bool doit_prologue();
  55   void doit_epilogue();
  56 };
  57 
  58 class VM_ShenandoahInitMark: public VM_ShenandoahOperation {
  59 public:
  60   VM_ShenandoahInitMark() : VM_ShenandoahOperation() {};
  61   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahInitMark; }
  62   const char* name()             const { return "Shenandoah Init Marking"; }
  63   virtual void doit();
  64 };
  65 
  66 class VM_ShenandoahFinalMarkStartEvac: public VM_ShenandoahReferenceOperation {
  67 public:
  68   VM_ShenandoahFinalMarkStartEvac() : VM_ShenandoahReferenceOperation() {};


  78   VM_ShenandoahFullGC(GCCause::Cause gc_cause) : VM_ShenandoahReferenceOperation(), _gc_cause(gc_cause) {};
  79   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahFullGC; }
  80   const char* name()             const { return "Shenandoah Full GC"; }
  81   virtual void doit();
  82 };
  83 
  84 class VM_ShenandoahPartialGC: public VM_ShenandoahOperation {
  85 public:
  86   VM_ShenandoahPartialGC() : VM_ShenandoahOperation() {};
  87   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahPartialGC; }
  88   const char* name()             const { return "Shenandoah Partial Collection"; }
  89   virtual void doit();
  90 };
  91 
  92 class VM_ShenandoahInitUpdateRefs: public VM_ShenandoahOperation {
  93 public:
  94   VM_ShenandoahInitUpdateRefs() : VM_ShenandoahOperation() {};
  95   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahInitUpdateRefs; }
  96   const char* name()             const { return "Shenandoah Init Update References"; }
  97   virtual void doit();
  98   // This is the only Shenandoah VM_Op that cannot take over deflation and nmethod marking.
  99   bool deflates_idle_monitors() { return false; }
 100   bool marks_nmethods() { return false; }
 101 };
 102 
 103 class VM_ShenandoahFinalUpdateRefs: public VM_ShenandoahOperation {
 104 public:
 105   VM_ShenandoahFinalUpdateRefs() : VM_ShenandoahOperation() {};
 106   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahFinalUpdateRefs; }
 107   const char* name()             const { return "Shenandoah Final Update References"; }
 108   virtual void doit();
 109 };
 110 
 111 class VM_ShenandoahVerifyHeapAfterEvacuation: public VM_ShenandoahOperation {
 112 public:
 113   VM_ShenandoahVerifyHeapAfterEvacuation() : VM_ShenandoahOperation() {};
 114   VM_Operation::VMOp_Type type() const { return VMOp_ShenandoahVerifyHeapAfterEvacuation; }
 115   const char* name()             const { return "Shenandoah verify heap after evacuation"; }
 116   virtual void doit();
 117   // We don't care about that here.
 118   bool deflates_idle_monitors() { return false; }
 119   bool marks_nmethods() { return false; }
 120 };
 121 
 122 #endif //SHARE_VM_GC_SHENANDOAH_VM_OPERATIONS_SHENANDOAH_HPP
< prev index next >