mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 06:45:07 +02:00
7188594: Print statistic collected by NMT with VM flag
Print out statistics of collected NMT data if it is on at VM exits Reviewed-by: kvn, coleenp, twisti
This commit is contained in:
parent
afd497eecc
commit
fb2076c572
4 changed files with 35 additions and 2 deletions
|
@ -85,7 +85,7 @@ class MemTracker : AllStatic {
|
|||
NMT_shutdown // shutdown
|
||||
};
|
||||
|
||||
|
||||
public:
|
||||
// native memory tracking level
|
||||
enum NMTLevel {
|
||||
NMT_off, // native memory tracking is off
|
||||
|
@ -93,7 +93,6 @@ class MemTracker : AllStatic {
|
|||
NMT_detail // track callsite also
|
||||
};
|
||||
|
||||
public:
|
||||
enum ShutdownReason {
|
||||
NMT_shutdown_none, // no shutdown requested
|
||||
NMT_shutdown_user, // user requested shutdown
|
||||
|
@ -117,6 +116,10 @@ class MemTracker : AllStatic {
|
|||
_state >= NMT_bootstrapping_single_thread);
|
||||
}
|
||||
|
||||
static inline enum NMTLevel tracking_level() {
|
||||
return _tracking_level;
|
||||
}
|
||||
|
||||
// user readable reason for shutting down NMT
|
||||
static const char* reason() {
|
||||
switch(_reason) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue