src/hotspot/share/services/memoryService.hpp
author erikj
Tue, 12 Sep 2017 19:03:39 +0200
changeset 47216 71c04702a3d5
parent 35061 hotspot/src/share/vm/services/memoryService.hpp@be6025ebffea
child 48168 cb5d2d4453d0
child 55767 8e22715afabc
permissions -rw-r--r--
8187443: Forest Consolidation: Move files to unified layout Reviewed-by: darcy, ihse
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
     1
/*
29684
a36d90acae41 8057632: Remove auxiliary code used to handle the generations array
jwilhelm
parents: 26796
diff changeset
     2
 * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved.
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
489c9b5090e2 Initial load
duke
parents:
diff changeset
     4
 *
489c9b5090e2 Initial load
duke
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
489c9b5090e2 Initial load
duke
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
489c9b5090e2 Initial load
duke
parents:
diff changeset
     7
 * published by the Free Software Foundation.
489c9b5090e2 Initial load
duke
parents:
diff changeset
     8
 *
489c9b5090e2 Initial load
duke
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
489c9b5090e2 Initial load
duke
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
489c9b5090e2 Initial load
duke
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
489c9b5090e2 Initial load
duke
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
489c9b5090e2 Initial load
duke
parents:
diff changeset
    13
 * accompanied this code).
489c9b5090e2 Initial load
duke
parents:
diff changeset
    14
 *
489c9b5090e2 Initial load
duke
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
489c9b5090e2 Initial load
duke
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
489c9b5090e2 Initial load
duke
parents:
diff changeset
    18
 *
5547
f4b087cbb361 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 4459
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
f4b087cbb361 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 4459
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
f4b087cbb361 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 4459
diff changeset
    21
 * questions.
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    22
 *
489c9b5090e2 Initial load
duke
parents:
diff changeset
    23
 */
489c9b5090e2 Initial load
duke
parents:
diff changeset
    24
7397
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
    25
#ifndef SHARE_VM_SERVICES_MEMORYSERVICE_HPP
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
    26
#define SHARE_VM_SERVICES_MEMORYSERVICE_HPP
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
    27
30764
fec48bf5a827 8079792: GC directory structure cleanup
pliden
parents: 29684
diff changeset
    28
#include "gc/shared/gcCause.hpp"
fec48bf5a827 8079792: GC directory structure cleanup
pliden
parents: 29684
diff changeset
    29
#include "gc/shared/generation.hpp"
35061
be6025ebffea 8145092: Use Unified Logging for the GC logging
brutisso
parents: 32623
diff changeset
    30
#include "logging/log.hpp"
7397
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
    31
#include "memory/allocation.hpp"
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
    32
#include "runtime/handles.hpp"
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
    33
#include "services/memoryUsage.hpp"
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
    34
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    35
// Forward declaration
489c9b5090e2 Initial load
duke
parents:
diff changeset
    36
class MemoryPool;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    37
class MemoryManager;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    38
class GCMemoryManager;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    39
class CollectedHeap;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    40
class Generation;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    41
class DefNewGeneration;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    42
class PSYoungGen;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    43
class PSOldGen;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    44
class CodeHeap;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    45
class ContiguousSpace;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    46
class CompactibleFreeListSpace;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    47
class GenCollectedHeap;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    48
class ParallelScavengeHeap;
4459
eb506d590394 6815790: G1: Missing MemoryPoolMXBeans with -XX:+UseG1GC
tonyp
parents: 1
diff changeset
    49
class G1CollectedHeap;
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    50
489c9b5090e2 Initial load
duke
parents:
diff changeset
    51
// VM Monitoring and Management Support
489c9b5090e2 Initial load
duke
parents:
diff changeset
    52
489c9b5090e2 Initial load
duke
parents:
diff changeset
    53
class MemoryService : public AllStatic {
489c9b5090e2 Initial load
duke
parents:
diff changeset
    54
private:
489c9b5090e2 Initial load
duke
parents:
diff changeset
    55
  enum {
489c9b5090e2 Initial load
duke
parents:
diff changeset
    56
    init_pools_list_size = 10,
26796
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
    57
    init_managers_list_size = 5,
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
    58
    init_code_heap_pools_size = 9
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    59
  };
489c9b5090e2 Initial load
duke
parents:
diff changeset
    60
489c9b5090e2 Initial load
duke
parents:
diff changeset
    61
  static GrowableArray<MemoryPool*>*    _pools_list;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    62
  static GrowableArray<MemoryManager*>* _managers_list;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    63
489c9b5090e2 Initial load
duke
parents:
diff changeset
    64
  // memory managers for minor and major GC statistics
489c9b5090e2 Initial load
duke
parents:
diff changeset
    65
  static GCMemoryManager*               _major_gc_manager;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    66
  static GCMemoryManager*               _minor_gc_manager;
489c9b5090e2 Initial load
duke
parents:
diff changeset
    67
26796
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
    68
  // memory manager and code heap pools for the CodeCache
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
    69
  static MemoryManager*                 _code_cache_manager;
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
    70
  static GrowableArray<MemoryPool*>*    _code_heap_pools;
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    71
18444
8adb4bc92f18 8013590: NPG: Add a memory pool MXBean for Metaspace
ehelin
parents: 16453
diff changeset
    72
  static MemoryPool*                    _metaspace_pool;
8adb4bc92f18 8013590: NPG: Add a memory pool MXBean for Metaspace
ehelin
parents: 16453
diff changeset
    73
  static MemoryPool*                    _compressed_class_pool;
8adb4bc92f18 8013590: NPG: Add a memory pool MXBean for Metaspace
ehelin
parents: 16453
diff changeset
    74
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    75
  static void add_generation_memory_pool(Generation* gen,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    76
                                         MemoryManager* major_mgr,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    77
                                         MemoryManager* minor_mgr);
489c9b5090e2 Initial load
duke
parents:
diff changeset
    78
  static void add_generation_memory_pool(Generation* gen,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    79
                                         MemoryManager* major_mgr) {
489c9b5090e2 Initial load
duke
parents:
diff changeset
    80
    add_generation_memory_pool(gen, major_mgr, NULL);
489c9b5090e2 Initial load
duke
parents:
diff changeset
    81
  }
489c9b5090e2 Initial load
duke
parents:
diff changeset
    82
489c9b5090e2 Initial load
duke
parents:
diff changeset
    83
32623
390a27af5657 8134626: Misc cleanups after generation array removal
jwilhelm
parents: 30764
diff changeset
    84
  static void add_psYoung_memory_pool(PSYoungGen* young_gen,
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    85
                                      MemoryManager* major_mgr,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    86
                                      MemoryManager* minor_mgr);
32623
390a27af5657 8134626: Misc cleanups after generation array removal
jwilhelm
parents: 30764
diff changeset
    87
  static void add_psOld_memory_pool(PSOldGen* old_gen,
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    88
                                    MemoryManager* mgr);
489c9b5090e2 Initial load
duke
parents:
diff changeset
    89
4459
eb506d590394 6815790: G1: Missing MemoryPoolMXBeans with -XX:+UseG1GC
tonyp
parents: 1
diff changeset
    90
  static void add_g1YoungGen_memory_pool(G1CollectedHeap* g1h,
eb506d590394 6815790: G1: Missing MemoryPoolMXBeans with -XX:+UseG1GC
tonyp
parents: 1
diff changeset
    91
                                         MemoryManager* major_mgr,
eb506d590394 6815790: G1: Missing MemoryPoolMXBeans with -XX:+UseG1GC
tonyp
parents: 1
diff changeset
    92
                                         MemoryManager* minor_mgr);
eb506d590394 6815790: G1: Missing MemoryPoolMXBeans with -XX:+UseG1GC
tonyp
parents: 1
diff changeset
    93
  static void add_g1OldGen_memory_pool(G1CollectedHeap* g1h,
eb506d590394 6815790: G1: Missing MemoryPoolMXBeans with -XX:+UseG1GC
tonyp
parents: 1
diff changeset
    94
                                       MemoryManager* mgr);
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
    95
489c9b5090e2 Initial load
duke
parents:
diff changeset
    96
  static MemoryPool* add_space(ContiguousSpace* space,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    97
                               const char* name,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    98
                               bool is_heap,
489c9b5090e2 Initial load
duke
parents:
diff changeset
    99
                               size_t max_size,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   100
                               bool support_usage_threshold);
32623
390a27af5657 8134626: Misc cleanups after generation array removal
jwilhelm
parents: 30764
diff changeset
   101
  static MemoryPool* add_survivor_spaces(DefNewGeneration* young_gen,
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   102
                                         const char* name,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   103
                                         bool is_heap,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   104
                                         size_t max_size,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   105
                                         bool support_usage_threshold);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   106
  static MemoryPool* add_gen(Generation* gen,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   107
                             const char* name,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   108
                             bool is_heap,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   109
                             bool support_usage_threshold);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   110
  static MemoryPool* add_cms_space(CompactibleFreeListSpace* space,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   111
                                   const char* name,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   112
                                   bool is_heap,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   113
                                   size_t max_size,
489c9b5090e2 Initial load
duke
parents:
diff changeset
   114
                                   bool support_usage_threshold);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   115
489c9b5090e2 Initial load
duke
parents:
diff changeset
   116
  static void add_gen_collected_heap_info(GenCollectedHeap* heap);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   117
  static void add_parallel_scavenge_heap_info(ParallelScavengeHeap* heap);
4459
eb506d590394 6815790: G1: Missing MemoryPoolMXBeans with -XX:+UseG1GC
tonyp
parents: 1
diff changeset
   118
  static void add_g1_heap_info(G1CollectedHeap* g1h);
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   119
489c9b5090e2 Initial load
duke
parents:
diff changeset
   120
public:
489c9b5090e2 Initial load
duke
parents:
diff changeset
   121
  static void set_universe_heap(CollectedHeap* heap);
26796
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
   122
  static void add_code_heap_memory_pool(CodeHeap* heap, const char* name);
18444
8adb4bc92f18 8013590: NPG: Add a memory pool MXBean for Metaspace
ehelin
parents: 16453
diff changeset
   123
  static void add_metaspace_memory_pools();
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   124
489c9b5090e2 Initial load
duke
parents:
diff changeset
   125
  static MemoryPool*    get_memory_pool(instanceHandle pool);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   126
  static MemoryManager* get_memory_manager(instanceHandle mgr);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   127
489c9b5090e2 Initial load
duke
parents:
diff changeset
   128
  static const int num_memory_pools() {
489c9b5090e2 Initial load
duke
parents:
diff changeset
   129
    return _pools_list->length();
489c9b5090e2 Initial load
duke
parents:
diff changeset
   130
  }
489c9b5090e2 Initial load
duke
parents:
diff changeset
   131
  static const int num_memory_managers() {
489c9b5090e2 Initial load
duke
parents:
diff changeset
   132
    return _managers_list->length();
489c9b5090e2 Initial load
duke
parents:
diff changeset
   133
  }
489c9b5090e2 Initial load
duke
parents:
diff changeset
   134
489c9b5090e2 Initial load
duke
parents:
diff changeset
   135
  static MemoryPool* get_memory_pool(int index) {
489c9b5090e2 Initial load
duke
parents:
diff changeset
   136
    return _pools_list->at(index);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   137
  }
489c9b5090e2 Initial load
duke
parents:
diff changeset
   138
489c9b5090e2 Initial load
duke
parents:
diff changeset
   139
  static MemoryManager* get_memory_manager(int index) {
489c9b5090e2 Initial load
duke
parents:
diff changeset
   140
    return _managers_list->at(index);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   141
  }
489c9b5090e2 Initial load
duke
parents:
diff changeset
   142
489c9b5090e2 Initial load
duke
parents:
diff changeset
   143
  static void track_memory_usage();
489c9b5090e2 Initial load
duke
parents:
diff changeset
   144
  static void track_code_cache_memory_usage() {
26796
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
   145
    // Track memory pool usage of all CodeCache memory pools
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
   146
    for (int i = 0; i < _code_heap_pools->length(); ++i) {
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
   147
      track_memory_pool_usage(_code_heap_pools->at(i));
666464578742 8015774: Add support for multiple code heaps
thartmann
parents: 22234
diff changeset
   148
    }
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   149
  }
20407
68e215ce8944 8025996: Track metaspace usage when metaspace is expanded
stefank
parents: 18444
diff changeset
   150
  static void track_metaspace_memory_usage() {
68e215ce8944 8025996: Track metaspace usage when metaspace is expanded
stefank
parents: 18444
diff changeset
   151
    track_memory_pool_usage(_metaspace_pool);
68e215ce8944 8025996: Track metaspace usage when metaspace is expanded
stefank
parents: 18444
diff changeset
   152
  }
68e215ce8944 8025996: Track metaspace usage when metaspace is expanded
stefank
parents: 18444
diff changeset
   153
  static void track_compressed_class_memory_usage() {
68e215ce8944 8025996: Track metaspace usage when metaspace is expanded
stefank
parents: 18444
diff changeset
   154
    track_memory_pool_usage(_compressed_class_pool);
68e215ce8944 8025996: Track metaspace usage when metaspace is expanded
stefank
parents: 18444
diff changeset
   155
  }
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   156
  static void track_memory_pool_usage(MemoryPool* pool);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   157
6245
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   158
  static void gc_begin(bool fullGC, bool recordGCBeginTime,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   159
                       bool recordAccumulatedGCTime,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   160
                       bool recordPreGCUsage, bool recordPeakUsage);
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   161
  static void gc_end(bool fullGC, bool recordPostGCUsage,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   162
                     bool recordAccumulatedGCTime,
9623
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   163
                     bool recordGCEndTime, bool countCollection,
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   164
                     GCCause::Cause cause);
6245
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   165
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   166
  static void oops_do(OopClosure* f);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   167
35061
be6025ebffea 8145092: Use Unified Logging for the GC logging
brutisso
parents: 32623
diff changeset
   168
  static bool get_verbose() { return log_is_enabled(Info, gc); }
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   169
  static bool set_verbose(bool verbose);
489c9b5090e2 Initial load
duke
parents:
diff changeset
   170
489c9b5090e2 Initial load
duke
parents:
diff changeset
   171
  // Create an instance of java/lang/management/MemoryUsage
489c9b5090e2 Initial load
duke
parents:
diff changeset
   172
  static Handle create_MemoryUsage_obj(MemoryUsage usage, TRAPS);
9623
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   173
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   174
  static const GCMemoryManager* get_minor_gc_manager() {
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   175
      return _minor_gc_manager;
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   176
  }
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   177
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   178
  static const GCMemoryManager* get_major_gc_manager() {
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   179
      return _major_gc_manager;
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   180
  }
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   181
};
489c9b5090e2 Initial load
duke
parents:
diff changeset
   182
489c9b5090e2 Initial load
duke
parents:
diff changeset
   183
class TraceMemoryManagerStats : public StackObj {
489c9b5090e2 Initial load
duke
parents:
diff changeset
   184
private:
489c9b5090e2 Initial load
duke
parents:
diff changeset
   185
  bool         _fullGC;
6245
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   186
  bool         _recordGCBeginTime;
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   187
  bool         _recordPreGCUsage;
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   188
  bool         _recordPeakUsage;
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   189
  bool         _recordPostGCUsage;
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   190
  bool         _recordAccumulatedGCTime;
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   191
  bool         _recordGCEndTime;
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   192
  bool         _countCollection;
9623
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   193
  GCCause::Cause _cause;
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   194
public:
6245
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   195
  TraceMemoryManagerStats() {}
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   196
  TraceMemoryManagerStats(bool fullGC,
9623
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   197
                          GCCause::Cause cause,
6245
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   198
                          bool recordGCBeginTime = true,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   199
                          bool recordPreGCUsage = true,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   200
                          bool recordPeakUsage = true,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   201
                          bool recordPostGCUsage = true,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   202
                          bool recordAccumulatedGCTime = true,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   203
                          bool recordGCEndTime = true,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   204
                          bool countCollection = true);
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   205
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   206
  void initialize(bool fullGC,
9623
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   207
                  GCCause::Cause cause,
6245
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   208
                  bool recordGCBeginTime,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   209
                  bool recordPreGCUsage,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   210
                  bool recordPeakUsage,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   211
                  bool recordPostGCUsage,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   212
                  bool recordAccumulatedGCTime,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   213
                  bool recordGCEndTime,
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   214
                  bool countCollection);
c37d2cf6de1a 6581734: CMS Old Gen's collection usage is zero after GC which is incorrect
kevinw
parents: 5547
diff changeset
   215
9623
151c0b638488 7036199: Adding a notification to the implementation of GarbageCollectorMXBeans
fparain
parents: 7397
diff changeset
   216
  TraceMemoryManagerStats(Generation::Name kind, GCCause::Cause cause);
1
489c9b5090e2 Initial load
duke
parents:
diff changeset
   217
  ~TraceMemoryManagerStats();
489c9b5090e2 Initial load
duke
parents:
diff changeset
   218
};
7397
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
   219
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6245
diff changeset
   220
#endif // SHARE_VM_SERVICES_MEMORYSERVICE_HPP