1.1 --- a/src/share/vm/gc_implementation/g1/heapRegionRemSet.hpp Fri Jan 21 11:30:22 2011 -0500 1.2 +++ b/src/share/vm/gc_implementation/g1/heapRegionRemSet.hpp Tue Jan 25 17:58:19 2011 -0500 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 2001, 2010, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved. 1.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.8 * 1.9 * This code is free software; you can redistribute it and/or modify it 1.10 @@ -38,6 +38,10 @@ 1.11 class PosParPRT; 1.12 class SparsePRT; 1.13 1.14 +// Essentially a wrapper around SparsePRTCleanupTask. See 1.15 +// sparsePRT.hpp for more details. 1.16 +class HRRSCleanupTask : public SparsePRTCleanupTask { 1.17 +}; 1.18 1.19 // The "_coarse_map" is a bitmap with one bit for each region, where set 1.20 // bits indicate that the corresponding region may contain some pointer 1.21 @@ -156,6 +160,8 @@ 1.22 // "from_hr" is being cleared; remove any entries from it. 1.23 void clear_incoming_entry(HeapRegion* from_hr); 1.24 1.25 + void do_cleanup_work(HRRSCleanupTask* hrrs_cleanup_task); 1.26 + 1.27 // Declare the heap size (in # of regions) to the OtherRegionsTable. 1.28 // (Uses it to initialize from_card_cache). 1.29 static void init_from_card_cache(size_t max_regions); 1.30 @@ -165,10 +171,8 @@ 1.31 static void shrink_from_card_cache(size_t new_n_regs); 1.32 1.33 static void print_from_card_cache(); 1.34 - 1.35 }; 1.36 1.37 - 1.38 class HeapRegionRemSet : public CHeapObj { 1.39 friend class VMStructs; 1.40 friend class HeapRegionRemSetIterator; 1.41 @@ -342,11 +346,16 @@ 1.42 static void print_recorded(); 1.43 static void record_event(Event evnt); 1.44 1.45 + // These are wrappers for the similarly-named methods on 1.46 + // SparsePRT. Look at sparsePRT.hpp for more details. 1.47 + static void reset_for_cleanup_tasks(); 1.48 + void do_cleanup_work(HRRSCleanupTask* hrrs_cleanup_task); 1.49 + static void finish_cleanup_task(HRRSCleanupTask* hrrs_cleanup_task); 1.50 + 1.51 // Run unit tests. 1.52 #ifndef PRODUCT 1.53 static void test(); 1.54 #endif 1.55 - 1.56 }; 1.57 1.58 class HeapRegionRemSetIterator : public CHeapObj {