src/share/vm/services/memoryManager.hpp

Print this page

        

@@ -150,11 +150,12 @@
 private:
   // TODO: We should unify the GCCounter and GCMemoryManager statistic
   size_t       _num_collections;
   elapsedTimer _accumulated_timer;
   elapsedTimer _gc_timer;         // for measuring every GC duration
-  GCStatInfo*  _last_gc_stat;
+  GCStatInfo*  volatile _last_gc_stat;
+  GCStatInfo*  volatile _current_gc_stat;
   int          _num_gc_threads;
 public:
   GCMemoryManager();
   ~GCMemoryManager();
 

@@ -164,13 +165,16 @@
   jlong  gc_time_ms()                   { return _accumulated_timer.milliseconds(); }
   size_t gc_count()                     { return _num_collections; }
   int    num_gc_threads()               { return _num_gc_threads; }
   void   set_num_gc_threads(int count)  { _num_gc_threads = count; }
 
-  void   gc_begin();
-  void   gc_end();
+  void   gc_begin(bool recordGCBeginTime, bool recordPreGCUsage,
+                  bool recordAccumulatedGCTime);
+  void   gc_end(bool recordPostGCUsage, bool recordAccumulatedGCTime,
+                bool recordGCEndTime, bool countCollection);
 
+
   void        reset_gc_stat()   { _num_collections = 0; _accumulated_timer.reset(); }
   GCStatInfo* last_gc_stat()    { return _last_gc_stat; }
 
   virtual MemoryManager::Name kind() = 0;
 };