--- a/src/hotspot/share/gc/g1/g1ParScanThreadState.hpp Wed Nov 29 18:43:35 2017 -0800
+++ b/src/hotspot/share/gc/g1/g1ParScanThreadState.hpp Tue Nov 28 21:43:45 2017 +0100
@@ -204,24 +204,8 @@
bool _flushed;
public:
- G1ParScanThreadStateSet(G1CollectedHeap* g1h, uint n_workers, size_t young_cset_length) :
- _g1h(g1h),
- _states(NEW_C_HEAP_ARRAY(G1ParScanThreadState*, n_workers, mtGC)),
- _surviving_young_words_total(NEW_C_HEAP_ARRAY(size_t, young_cset_length, mtGC)),
- _young_cset_length(young_cset_length),
- _n_workers(n_workers),
- _flushed(false) {
- for (uint i = 0; i < n_workers; ++i) {
- _states[i] = NULL;
- }
- memset(_surviving_young_words_total, 0, young_cset_length * sizeof(size_t));
- }
-
- ~G1ParScanThreadStateSet() {
- assert(_flushed, "thread local state from the per thread states should have been flushed");
- FREE_C_HEAP_ARRAY(G1ParScanThreadState*, _states);
- FREE_C_HEAP_ARRAY(size_t, _surviving_young_words_total);
- }
+ G1ParScanThreadStateSet(G1CollectedHeap* g1h, uint n_workers, size_t young_cset_length);
+ ~G1ParScanThreadStateSet();
void flush();