mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 11:04:34 +02:00
Merge
This commit is contained in:
commit
d4f955a545
4 changed files with 12 additions and 9 deletions
|
@ -1308,8 +1308,7 @@ void MetaspaceGC::compute_new_size() {
|
|||
gclog_or_tty->print_cr(" metaspace HWM: %.1fK", new_capacity_until_GC / (double) K);
|
||||
}
|
||||
}
|
||||
assert(vsl->used_bytes_sum() == used_after_gc &&
|
||||
used_after_gc <= vsl->capacity_bytes_sum(),
|
||||
assert(used_after_gc <= vsl->capacity_bytes_sum(),
|
||||
"sanity check");
|
||||
|
||||
}
|
||||
|
@ -1969,6 +1968,9 @@ void SpaceManager::initialize() {
|
|||
}
|
||||
|
||||
SpaceManager::~SpaceManager() {
|
||||
// This call this->_lock which can't be done while holding expand_lock()
|
||||
const size_t in_use_before = sum_capacity_in_chunks_in_use();
|
||||
|
||||
MutexLockerEx fcl(SpaceManager::expand_lock(),
|
||||
Mutex::_no_safepoint_check_flag);
|
||||
|
||||
|
@ -1986,7 +1988,7 @@ SpaceManager::~SpaceManager() {
|
|||
|
||||
// Have to update before the chunks_in_use lists are emptied
|
||||
// below.
|
||||
chunk_manager->inc_free_chunks_total(sum_capacity_in_chunks_in_use(),
|
||||
chunk_manager->inc_free_chunks_total(in_use_before,
|
||||
sum_count_in_chunks_in_use());
|
||||
|
||||
// Add all the chunks in use by this space manager
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue