mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 06:14:49 +02:00
8027295: Free CSet takes ~50% of young pause time
Improve fast card cache iteration and avoid taking locks when freeing the collection set. Reviewed-by: brutisso
This commit is contained in:
parent
cde8aa670b
commit
d3e28ca682
7 changed files with 54 additions and 13 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2001, 2014, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -205,7 +205,7 @@ void HeapRegion::reset_after_compaction() {
|
|||
init_top_at_mark_start();
|
||||
}
|
||||
|
||||
void HeapRegion::hr_clear(bool par, bool clear_space) {
|
||||
void HeapRegion::hr_clear(bool par, bool clear_space, bool locked) {
|
||||
assert(_humongous_type == NotHumongous,
|
||||
"we should have already filtered out humongous regions");
|
||||
assert(_humongous_start_region == NULL,
|
||||
|
@ -223,7 +223,11 @@ void HeapRegion::hr_clear(bool par, bool clear_space) {
|
|||
if (!par) {
|
||||
// If this is parallel, this will be done later.
|
||||
HeapRegionRemSet* hrrs = rem_set();
|
||||
hrrs->clear();
|
||||
if (locked) {
|
||||
hrrs->clear_locked();
|
||||
} else {
|
||||
hrrs->clear();
|
||||
}
|
||||
_claimed = InitialClaimValue;
|
||||
}
|
||||
zero_marked_bytes();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue