mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 22:34:27 +02:00
6711316: Open source the Garbage-First garbage collector
First mercurial integration of the code for the Garbage-First garbage collector. Reviewed-by: apetrusenko, iveresov, jmasa, sgoldman, tonyp, ysr
This commit is contained in:
parent
39463bb3fc
commit
18f3386a98
215 changed files with 36088 additions and 1249 deletions
|
@ -65,7 +65,8 @@ void ParallelTaskTerminator::sleep(uint millis) {
|
|||
os::sleep(Thread::current(), millis, false);
|
||||
}
|
||||
|
||||
bool ParallelTaskTerminator::offer_termination() {
|
||||
bool
|
||||
ParallelTaskTerminator::offer_termination(TerminatorTerminator* terminator) {
|
||||
Atomic::inc(&_offered_termination);
|
||||
|
||||
juint yield_count = 0;
|
||||
|
@ -91,7 +92,8 @@ bool ParallelTaskTerminator::offer_termination() {
|
|||
sleep(WorkStealingSleepMillis);
|
||||
}
|
||||
|
||||
if (peek_in_queue_set()) {
|
||||
if (peek_in_queue_set() ||
|
||||
(terminator != NULL && terminator->should_exit_termination())) {
|
||||
Atomic::dec(&_offered_termination);
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue