hotspot/src/share/vm/gc/g1/concurrentG1Refine.cpp
author ehelin
Mon, 19 Oct 2015 15:47:36 +0200
changeset 34131 d5fc001452bb
parent 33608 7afc768e4d62
child 36371 fd81a4f0ea00
permissions -rw-r--r--
8139883: Add virtual destructor G1ParScanThreadState Reviewed-by: tschatzl, mgerdin, stefank
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     1
/*
30764
fec48bf5a827 8079792: GC directory structure cleanup
pliden
parents: 27880
diff changeset
     2
 * Copyright (c) 2001, 2015, Oracle and/or its affiliates. All rights reserved.
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     4
 *
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     7
 * published by the Free Software Foundation.
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     8
 *
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    13
 * accompanied this code).
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    14
 *
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    18
 *
5547
f4b087cbb361 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 5033
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
f4b087cbb361 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 5033
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
f4b087cbb361 6941466: Oracle rebranding changes for Hotspot repositories
trims
parents: 5033
diff changeset
    21
 * questions.
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    22
 *
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    23
 */
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    24
7397
5b173b4ca846 6989984: Use standard include model for Hospot
stefank
parents: 6247
diff changeset
    25
#include "precompiled.hpp"
30764
fec48bf5a827 8079792: GC directory structure cleanup
pliden
parents: 27880
diff changeset
    26
#include "gc/g1/concurrentG1Refine.hpp"
fec48bf5a827 8079792: GC directory structure cleanup
pliden
parents: 27880
diff changeset
    27
#include "gc/g1/concurrentG1RefineThread.hpp"
fec48bf5a827 8079792: GC directory structure cleanup
pliden
parents: 27880
diff changeset
    28
#include "gc/g1/g1CollectedHeap.inline.hpp"
fec48bf5a827 8079792: GC directory structure cleanup
pliden
parents: 27880
diff changeset
    29
#include "gc/g1/g1HotCardCache.hpp"
22220
eb467dfb9585 8029326: G1 does not check if threads gets created
ehelin
parents: 17854
diff changeset
    30
#include "runtime/java.hpp"
8926
717a49db1743 7026932: G1: No need to abort VM when card count cache expansion fails
johnc
parents: 8683
diff changeset
    31
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    32
ConcurrentG1Refine::ConcurrentG1Refine(G1CollectedHeap* g1h) :
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    33
  _threads(NULL),
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    34
  _sample_thread(NULL),
17327
4bd0581aa231 7176479: G1: JVM crashes on T5-8 system with 1.5 TB heap
johnc
parents: 13289
diff changeset
    35
  _hot_card_cache(g1h)
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    36
{
22551
9bf46d16dcc6 8025856: Fix typos in the GC code
jwilhelm
parents: 22220
diff changeset
    37
  // Ergonomically select initial concurrent refinement parameters
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    38
  if (FLAG_IS_DEFAULT(G1ConcRefinementGreenZone)) {
30876
44a71334fd94 8080876: Replace unnecessary MAX2(ParallelGCThreads, 1) calls with ParallelGCThreads
stefank
parents: 30764
diff changeset
    39
    FLAG_SET_DEFAULT(G1ConcRefinementGreenZone, (intx)ParallelGCThreads);
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    40
  }
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    41
  set_green_zone(G1ConcRefinementGreenZone);
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    42
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    43
  if (FLAG_IS_DEFAULT(G1ConcRefinementYellowZone)) {
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    44
    FLAG_SET_DEFAULT(G1ConcRefinementYellowZone, green_zone() * 3);
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    45
  }
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    46
  set_yellow_zone(MAX2<int>(G1ConcRefinementYellowZone, green_zone()));
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    47
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    48
  if (FLAG_IS_DEFAULT(G1ConcRefinementRedZone)) {
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    49
    FLAG_SET_DEFAULT(G1ConcRefinementRedZone, yellow_zone() * 2);
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    50
  }
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
    51
  set_red_zone(MAX2<int>(G1ConcRefinementRedZone, yellow_zone()));
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    52
}
17327
4bd0581aa231 7176479: G1: JVM crashes on T5-8 system with 1.5 TB heap
johnc
parents: 13289
diff changeset
    53
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    54
ConcurrentG1Refine* ConcurrentG1Refine::create(G1CollectedHeap* g1h, CardTableEntryClosure* refine_closure, jint* ecode) {
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    55
  ConcurrentG1Refine* cg1r = new ConcurrentG1Refine(g1h);
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    56
  if (cg1r == NULL) {
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    57
    *ecode = JNI_ENOMEM;
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    58
    vm_shutdown_during_initialization("Could not create ConcurrentG1Refine");
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    59
    return NULL;
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    60
  }
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    61
  cg1r->_n_worker_threads = thread_num();
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    62
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    63
  cg1r->reset_threshold_step();
17327
4bd0581aa231 7176479: G1: JVM crashes on T5-8 system with 1.5 TB heap
johnc
parents: 13289
diff changeset
    64
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    65
  cg1r->_threads = NEW_C_HEAP_ARRAY_RETURN_NULL(ConcurrentG1RefineThread*, cg1r->_n_worker_threads, mtGC);
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    66
  if (cg1r->_threads == NULL) {
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    67
    *ecode = JNI_ENOMEM;
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    68
    vm_shutdown_during_initialization("Could not allocate an array for ConcurrentG1RefineThread");
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    69
    return NULL;
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    70
  }
17327
4bd0581aa231 7176479: G1: JVM crashes on T5-8 system with 1.5 TB heap
johnc
parents: 13289
diff changeset
    71
23855
c4574075402c 8016302: Change type of the number of GC workers to unsigned int (2)
vkempik
parents: 22551
diff changeset
    72
  uint worker_id_offset = DirtyCardQueueSet::num_par_ids();
17327
4bd0581aa231 7176479: G1: JVM crashes on T5-8 system with 1.5 TB heap
johnc
parents: 13289
diff changeset
    73
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    74
  ConcurrentG1RefineThread *next = NULL;
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    75
  for (uint i = cg1r->_n_worker_threads - 1; i != UINT_MAX; i--) {
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    76
    ConcurrentG1RefineThread* t = new ConcurrentG1RefineThread(cg1r, next, refine_closure, worker_id_offset, i);
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    77
    assert(t != NULL, "Conc refine should have been created");
22220
eb467dfb9585 8029326: G1 does not check if threads gets created
ehelin
parents: 17854
diff changeset
    78
    if (t->osthread() == NULL) {
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    79
      *ecode = JNI_ENOMEM;
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    80
      vm_shutdown_during_initialization("Could not create ConcurrentG1RefineThread");
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    81
      return NULL;
22220
eb467dfb9585 8029326: G1 does not check if threads gets created
ehelin
parents: 17854
diff changeset
    82
    }
eb467dfb9585 8029326: G1 does not check if threads gets created
ehelin
parents: 17854
diff changeset
    83
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    84
    assert(t->cg1r() == cg1r, "Conc refine thread should refer to this");
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    85
    cg1r->_threads[i] = t;
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
    86
    next = t;
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    87
  }
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    88
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    89
  cg1r->_sample_thread = new G1YoungRemSetSamplingThread();
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    90
  if (cg1r->_sample_thread->osthread() == NULL) {
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    91
    *ecode = JNI_ENOMEM;
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    92
    vm_shutdown_during_initialization("Could not create G1YoungRemSetSamplingThread");
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    93
    return NULL;
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    94
  }
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
    95
32738
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    96
  *ecode = JNI_OK;
a1adf25202fd 8135025: Error message is repeated for large value at G1ConcRefinementThreads
sangheki
parents: 30876
diff changeset
    97
  return cg1r;
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    98
}
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
    99
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   100
void ConcurrentG1Refine::reset_threshold_step() {
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
   101
  if (FLAG_IS_DEFAULT(G1ConcRefinementThresholdStep)) {
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   102
    _thread_threshold_step = (yellow_zone() - green_zone()) / (worker_thread_num() + 1);
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   103
  } else {
5033
55f476a32544 6928059: G1: command line parameter renaming
tonyp
parents: 4887
diff changeset
   104
    _thread_threshold_step = G1ConcRefinementThresholdStep;
2882
d508a8bac491 6841831: G1: assert(contains_reference(from),"We just added it!") fires
iveresov
parents: 2881
diff changeset
   105
  }
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   106
}
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   107
26160
aba6b01cb988 8038423: G1: Decommit memory within heap
tschatzl
parents: 24104
diff changeset
   108
void ConcurrentG1Refine::init(G1RegionToSpaceMapper* card_counts_storage) {
aba6b01cb988 8038423: G1: Decommit memory within heap
tschatzl
parents: 24104
diff changeset
   109
  _hot_card_cache.initialize(card_counts_storage);
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   110
}
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   111
2881
74a1337e4acc 6484957: G1: parallel concurrent refinement
iveresov
parents: 2249
diff changeset
   112
void ConcurrentG1Refine::stop() {
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   113
  for (uint i = 0; i < _n_worker_threads; i++) {
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   114
    _threads[i]->stop();
2881
74a1337e4acc 6484957: G1: parallel concurrent refinement
iveresov
parents: 2249
diff changeset
   115
  }
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   116
  _sample_thread->stop();
2881
74a1337e4acc 6484957: G1: parallel concurrent refinement
iveresov
parents: 2249
diff changeset
   117
}
74a1337e4acc 6484957: G1: parallel concurrent refinement
iveresov
parents: 2249
diff changeset
   118
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   119
void ConcurrentG1Refine::reinitialize_threads() {
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   120
  reset_threshold_step();
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   121
  for (uint i = 0; i < _n_worker_threads; i++) {
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   122
    _threads[i]->initialize();
4481
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   123
  }
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   124
}
de92ec484f5e 6862387: tune concurrent refinement further
iveresov
parents: 4022
diff changeset
   125
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   126
ConcurrentG1Refine::~ConcurrentG1Refine() {
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   127
  for (uint i = 0; i < _n_worker_threads; i++) {
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   128
    delete _threads[i];
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   129
  }
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   130
  FREE_C_HEAP_ARRAY(ConcurrentG1RefineThread*, _threads);
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   131
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   132
  delete _sample_thread;
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   133
}
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   134
2881
74a1337e4acc 6484957: G1: parallel concurrent refinement
iveresov
parents: 2249
diff changeset
   135
void ConcurrentG1Refine::threads_do(ThreadClosure *tc) {
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   136
  worker_threads_do(tc);
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   137
  tc->do_thread(_sample_thread);
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   138
}
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   139
17854
d65bc1546091 8013895: G1: G1SummarizeRSetStats output on Linux needs improvemen
tschatzl
parents: 17327
diff changeset
   140
void ConcurrentG1Refine::worker_threads_do(ThreadClosure * tc) {
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   141
  for (uint i = 0; i < worker_thread_num(); i++) {
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   142
    tc->do_thread(_threads[i]);
17854
d65bc1546091 8013895: G1: G1SummarizeRSetStats output on Linux needs improvemen
tschatzl
parents: 17327
diff changeset
   143
  }
d65bc1546091 8013895: G1: G1SummarizeRSetStats output on Linux needs improvemen
tschatzl
parents: 17327
diff changeset
   144
}
d65bc1546091 8013895: G1: G1SummarizeRSetStats output on Linux needs improvemen
tschatzl
parents: 17327
diff changeset
   145
23855
c4574075402c 8016302: Change type of the number of GC workers to unsigned int (2)
vkempik
parents: 22551
diff changeset
   146
uint ConcurrentG1Refine::thread_num() {
26932
33d6fa41d290 8047976: Ergonomics for GC thread counts should update the flags
jwilhelm
parents: 26160
diff changeset
   147
  return G1ConcRefinementThreads;
1374
4c24294029a9 6711316: Open source the Garbage-First garbage collector
ysr
parents:
diff changeset
   148
}
4022
2ec87d5043f7 6885041: G1: inconsistent thread dump
tonyp
parents: 3590
diff changeset
   149
2ec87d5043f7 6885041: G1: inconsistent thread dump
tonyp
parents: 3590
diff changeset
   150
void ConcurrentG1Refine::print_worker_threads_on(outputStream* st) const {
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   151
  for (uint i = 0; i < _n_worker_threads; ++i) {
4022
2ec87d5043f7 6885041: G1: inconsistent thread dump
tonyp
parents: 3590
diff changeset
   152
    _threads[i]->print_on(st);
2ec87d5043f7 6885041: G1: inconsistent thread dump
tonyp
parents: 3590
diff changeset
   153
    st->cr();
2ec87d5043f7 6885041: G1: inconsistent thread dump
tonyp
parents: 3590
diff changeset
   154
  }
33608
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   155
  _sample_thread->print_on(st);
7afc768e4d62 8138920: Refactor the sampling thread from ConcurrentG1RefineThread
drwhite
parents: 32738
diff changeset
   156
  st->cr();
4022
2ec87d5043f7 6885041: G1: inconsistent thread dump
tonyp
parents: 3590
diff changeset
   157
}