src/share/vm/services/memTrackWorker.hpp

Print this page
rev 3901 : JDK-8005012: Add WB APIs to better support NMT testing
Summary:


  49   ~MemTrackWorker();
  50   _NOINLINE_ void* operator new(size_t size);
  51   _NOINLINE_ void* operator new(size_t size, const std::nothrow_t& nothrow_constant);
  52 
  53   void start();
  54   void run();
  55 
  56   inline bool has_error() const { return _has_error; }
  57 
  58   // task at synchronization point
  59   void at_sync_point(MemRecorder* pending_recorders);
  60 
  61   // for debugging purpose, they are not thread safe.
  62   NOT_PRODUCT(static int count_recorder(const MemRecorder* head);)
  63   NOT_PRODUCT(int count_pending_recorders() const;)
  64 
  65   NOT_PRODUCT(int _sync_point_count;)
  66   NOT_PRODUCT(int _merge_count;)
  67   NOT_PRODUCT(int _last_gen_in_use;)
  68 

  69   inline int generations_in_use() const {
  70     return (_tail >= _head ? (_tail - _head + 1) : (MAX_GENERATIONS - (_head - _tail) + 1));
  71   }
  72 };
  73 
  74 #endif // SHARE_VM_SERVICES_MEM_TRACK_WORKER_HPP


  49   ~MemTrackWorker();
  50   _NOINLINE_ void* operator new(size_t size);
  51   _NOINLINE_ void* operator new(size_t size, const std::nothrow_t& nothrow_constant);
  52 
  53   void start();
  54   void run();
  55 
  56   inline bool has_error() const { return _has_error; }
  57 
  58   // task at synchronization point
  59   void at_sync_point(MemRecorder* pending_recorders);
  60 
  61   // for debugging purpose, they are not thread safe.
  62   NOT_PRODUCT(static int count_recorder(const MemRecorder* head);)
  63   NOT_PRODUCT(int count_pending_recorders() const;)
  64 
  65   NOT_PRODUCT(int _sync_point_count;)
  66   NOT_PRODUCT(int _merge_count;)
  67   NOT_PRODUCT(int _last_gen_in_use;)
  68 
  69   // how many generations are queued
  70   inline int generations_in_use() const {
  71     return (_tail >= _head ? (_tail - _head + 1) : (MAX_GENERATIONS - (_head - _tail) + 1));
  72   }
  73 };
  74 
  75 #endif // SHARE_VM_SERVICES_MEM_TRACK_WORKER_HPP