< prev index next >
src/hotspot/share/gc/g1/g1ConcurrentRefine.cpp
Print this page
rev 47675 : [mq]: 8149127-rename-concurrentrefine-a
rev 47676 : imported patch 8149127-rename-concurrentrefine-b
rev 47677 : [mq]: 8149127-rename-concurrentrefine-b-stefanj-review
rev 47678 : imported patch 8140255-move-sampling-thread
rev 47679 : [mq]: 8140255-update
@@ -23,11 +23,10 @@
*/
#include "precompiled.hpp"
#include "gc/g1/g1ConcurrentRefine.hpp"
#include "gc/g1/g1ConcurrentRefineThread.hpp"
-#include "gc/g1/g1YoungRemSetSamplingThread.hpp"
#include "logging/log.hpp"
#include "runtime/java.hpp"
#include "runtime/thread.hpp"
#include "utilities/debug.hpp"
#include "utilities/globalDefinitions.hpp"
@@ -115,11 +114,10 @@
G1ConcurrentRefine::G1ConcurrentRefine(size_t green_zone,
size_t yellow_zone,
size_t red_zone,
size_t min_yellow_zone_size) :
_threads(NULL),
- _sample_thread(NULL),
_n_worker_threads(thread_num()),
_green_zone(green_zone),
_yellow_zone(yellow_zone),
_red_zone(red_zone),
_min_yellow_zone_size(min_yellow_zone_size)
@@ -222,26 +220,18 @@
assert(t->cr() == cr, "Conc refine thread should refer to this");
cr->_threads[i] = t;
next = t;
}
- cr->_sample_thread = new G1YoungRemSetSamplingThread();
- if (cr->_sample_thread->osthread() == NULL) {
- *ecode = JNI_ENOMEM;
- vm_shutdown_during_initialization("Could not create G1YoungRemSetSamplingThread");
- return NULL;
- }
-
*ecode = JNI_OK;
return cr;
}
void G1ConcurrentRefine::stop() {
for (uint i = 0; i < _n_worker_threads; i++) {
_threads[i]->stop();
}
- _sample_thread->stop();
}
void G1ConcurrentRefine::update_thread_thresholds() {
for (uint i = 0; i < _n_worker_threads; i++) {
Thresholds thresholds = calc_thresholds(_green_zone, _yellow_zone, i);
@@ -253,36 +243,27 @@
G1ConcurrentRefine::~G1ConcurrentRefine() {
for (uint i = 0; i < _n_worker_threads; i++) {
delete _threads[i];
}
FREE_C_HEAP_ARRAY(G1ConcurrentRefineThread*, _threads);
-
- delete _sample_thread;
}
void G1ConcurrentRefine::threads_do(ThreadClosure *tc) {
- worker_threads_do(tc);
- tc->do_thread(_sample_thread);
-}
-
-void G1ConcurrentRefine::worker_threads_do(ThreadClosure * tc) {
for (uint i = 0; i < _n_worker_threads; i++) {
tc->do_thread(_threads[i]);
}
}
uint G1ConcurrentRefine::thread_num() {
return G1ConcRefinementThreads;
}
-void G1ConcurrentRefine::print_worker_threads_on(outputStream* st) const {
+void G1ConcurrentRefine::print_threads_on(outputStream* st) const {
for (uint i = 0; i < _n_worker_threads; ++i) {
_threads[i]->print_on(st);
st->cr();
}
- _sample_thread->print_on(st);
- st->cr();
}
static size_t calc_new_green_zone(size_t green,
double update_rs_time,
size_t update_rs_processed_buffers,
< prev index next >