8147884: Names of GC threads should be set before the threads start

Reviewed-by: mgerdin, david
This commit is contained in:
Artem Smotrakov 2016-02-03 09:31:22 -08:00
parent a95454d65c
commit 61a27307a4
2 changed files with 4 additions and 5 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2001, 2016, 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
@ -59,10 +59,10 @@ ConcurrentG1RefineThread(ConcurrentG1Refine* cg1r, ConcurrentG1RefineThread *nex
_monitor = DirtyCardQ_CBL_mon;
}
initialize();
create_and_start();
// set name
set_name("G1 Refine#%d", worker_id);
create_and_start();
}
void ConcurrentG1RefineThread::initialize() {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2016, 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
@ -61,9 +61,8 @@ G1YoungRemSetSamplingThread::G1YoungRemSetSamplingThread() : ConcurrentGCThread(
true,
Monitor::_safepoint_check_never);
create_and_start();
set_name("G1 Young RemSet Sampling");
create_and_start();
}
void G1YoungRemSetSamplingThread::sleep_before_next_cycle() {