comparison src/share/vm/runtime/perfData.hpp @ 6197:d2a62e0f25eb

6995781: Native Memory Tracking (Phase 1) 7151532: DCmd for hotspot native memory tracking Summary: Implementation of native memory tracking phase 1, which tracks VM native memory usage, and related DCmd Reviewed-by: acorn, coleenp, fparain
author zgu
date Thu, 28 Jun 2012 17:03:16 -0400
parents f95d63e2154a
children da91efe96a93
comparison
equal deleted inserted replaced
6174:74533f63b116 6197:d2a62e0f25eb
238 * manipulated within a guarded block. The guard variable is 238 * manipulated within a guarded block. The guard variable is
239 * UsePerfData, a product flag set to true by default. This flag may 239 * UsePerfData, a product flag set to true by default. This flag may
240 * be removed from the product in the future. 240 * be removed from the product in the future.
241 * 241 *
242 */ 242 */
243 class PerfData : public CHeapObj { 243 class PerfData : public CHeapObj<mtInternal> {
244 244
245 friend class StatSampler; // for access to protected void sample() 245 friend class StatSampler; // for access to protected void sample()
246 friend class PerfDataManager; // for access to protected destructor 246 friend class PerfDataManager; // for access to protected destructor
247 247
248 public: 248 public:
340 * PerfLongSampleHelper, and its alias PerfSamplerHelper, is a base class 340 * PerfLongSampleHelper, and its alias PerfSamplerHelper, is a base class
341 * for helper classes that rely upon the StatSampler periodic task to 341 * for helper classes that rely upon the StatSampler periodic task to
342 * invoke the take_sample() method and write the value returned to its 342 * invoke the take_sample() method and write the value returned to its
343 * appropriate location in the PerfData memory region. 343 * appropriate location in the PerfData memory region.
344 */ 344 */
345 class PerfLongSampleHelper : public CHeapObj { 345 class PerfLongSampleHelper : public CHeapObj<mtInternal> {
346 public: 346 public:
347 virtual jlong take_sample() = 0; 347 virtual jlong take_sample() = 0;
348 }; 348 };
349 349
350 typedef PerfLongSampleHelper PerfSampleHelper; 350 typedef PerfLongSampleHelper PerfSampleHelper;
589 * iterators and the at(int index) method. However, the GrowableArray 589 * iterators and the at(int index) method. However, the GrowableArray
590 * is not directly visible outside this class and can be replaced by 590 * is not directly visible outside this class and can be replaced by
591 * some other implementation, as long as that implementation provides 591 * some other implementation, as long as that implementation provides
592 * a mechanism to iterate over the container by index. 592 * a mechanism to iterate over the container by index.
593 */ 593 */
594 class PerfDataList : public CHeapObj { 594 class PerfDataList : public CHeapObj<mtInternal> {
595 595
596 private: 596 private:
597 597
598 // GrowableArray implementation 598 // GrowableArray implementation
599 typedef GrowableArray<PerfData*> PerfDataArray; 599 typedef GrowableArray<PerfData*> PerfDataArray;