equal
deleted
inserted
replaced
21 * questions. |
21 * questions. |
22 * |
22 * |
23 */ |
23 */ |
24 |
24 |
25 #include "precompiled.hpp" |
25 #include "precompiled.hpp" |
26 #include "gc/serial/defNewGeneration.hpp" |
|
27 #include "gc/shared/generation.hpp" |
26 #include "gc/shared/generation.hpp" |
28 #include "gc/shared/genMemoryPools.hpp" |
27 #include "gc/shared/genMemoryPools.hpp" |
29 #include "gc/shared/space.hpp" |
28 #include "gc/shared/space.hpp" |
|
29 #if INCLUDE_SERIALGC |
|
30 #include "gc/serial/defNewGeneration.hpp" |
|
31 #endif |
30 |
32 |
31 ContiguousSpacePool::ContiguousSpacePool(ContiguousSpace* space, |
33 ContiguousSpacePool::ContiguousSpacePool(ContiguousSpace* space, |
32 const char* name, |
34 const char* name, |
33 size_t max_size, |
35 size_t max_size, |
34 bool support_usage_threshold) : |
36 bool support_usage_threshold) : |
45 size_t used = used_in_bytes(); |
47 size_t used = used_in_bytes(); |
46 size_t committed = _space->capacity(); |
48 size_t committed = _space->capacity(); |
47 |
49 |
48 return MemoryUsage(initial_size(), used, committed, maxSize); |
50 return MemoryUsage(initial_size(), used, committed, maxSize); |
49 } |
51 } |
|
52 |
|
53 #if INCLUDE_SERIALGC |
50 |
54 |
51 SurvivorContiguousSpacePool::SurvivorContiguousSpacePool(DefNewGeneration* young_gen, |
55 SurvivorContiguousSpacePool::SurvivorContiguousSpacePool(DefNewGeneration* young_gen, |
52 const char* name, |
56 const char* name, |
53 size_t max_size, |
57 size_t max_size, |
54 bool support_usage_threshold) : |
58 bool support_usage_threshold) : |
70 size_t committed = committed_in_bytes(); |
74 size_t committed = committed_in_bytes(); |
71 |
75 |
72 return MemoryUsage(initial_size(), used, committed, maxSize); |
76 return MemoryUsage(initial_size(), used, committed, maxSize); |
73 } |
77 } |
74 |
78 |
|
79 #endif // INCLUDE_SERIALGC |
|
80 |
75 GenerationPool::GenerationPool(Generation* gen, |
81 GenerationPool::GenerationPool(Generation* gen, |
76 const char* name, |
82 const char* name, |
77 bool support_usage_threshold) : |
83 bool support_usage_threshold) : |
78 CollectedMemoryPool(name, gen->capacity(), gen->max_capacity(), |
84 CollectedMemoryPool(name, gen->capacity(), gen->max_capacity(), |
79 support_usage_threshold), _gen(gen) { |
85 support_usage_threshold), _gen(gen) { |