equal
deleted
inserted
replaced
22 * |
22 * |
23 */ |
23 */ |
24 |
24 |
25 #include "precompiled.hpp" |
25 #include "precompiled.hpp" |
26 #include "gc/serial/cSpaceCounters.hpp" |
26 #include "gc/serial/cSpaceCounters.hpp" |
|
27 #include "memory/allocation.inline.hpp" |
27 #include "memory/metaspace.hpp" |
28 #include "memory/metaspace.hpp" |
28 #include "memory/resourceArea.hpp" |
29 #include "memory/resourceArea.hpp" |
29 |
30 |
30 CSpaceCounters::CSpaceCounters(const char* name, int ordinal, size_t max_size, |
31 CSpaceCounters::CSpaceCounters(const char* name, int ordinal, size_t max_size, |
31 ContiguousSpace* s, GenerationCounters* gc) : |
32 ContiguousSpace* s, GenerationCounters* gc) : |
62 PerfDataManager::create_constant(SUN_GC, cname, PerfData::U_Bytes, |
63 PerfDataManager::create_constant(SUN_GC, cname, PerfData::U_Bytes, |
63 _space->capacity(), CHECK); |
64 _space->capacity(), CHECK); |
64 } |
65 } |
65 } |
66 } |
66 |
67 |
|
68 CSpaceCounters::~CSpaceCounters() { |
|
69 if (_name_space != NULL) FREE_C_HEAP_ARRAY(char, _name_space); |
|
70 } |
|
71 |
67 void CSpaceCounters::update_capacity() { |
72 void CSpaceCounters::update_capacity() { |
68 _capacity->set_value(_space->capacity()); |
73 _capacity->set_value(_space->capacity()); |
69 } |
74 } |
70 |
75 |
71 void CSpaceCounters::update_used() { |
76 void CSpaceCounters::update_used() { |