1.1 --- a/src/share/vm/memory/modRefBarrierSet.hpp Wed Jun 04 13:51:09 2008 -0700 1.2 +++ b/src/share/vm/memory/modRefBarrierSet.hpp Thu Jun 05 15:57:56 2008 -0700 1.3 @@ -31,6 +31,13 @@ 1.4 1.5 class ModRefBarrierSet: public BarrierSet { 1.6 public: 1.7 + 1.8 + ModRefBarrierSet() { _kind = BarrierSet::ModRef; } 1.9 + 1.10 + bool is_a(BarrierSet::Name bsn) { 1.11 + return bsn == BarrierSet::ModRef; 1.12 + } 1.13 + 1.14 // Barriers only on ref writes. 1.15 bool has_read_ref_barrier() { return false; } 1.16 bool has_read_prim_barrier() { return false; } 1.17 @@ -85,8 +92,10 @@ 1.18 bool clear = false, 1.19 bool before_save_marks = false) = 0; 1.20 1.21 - // Causes all refs in "mr" to be assumed to be modified. 1.22 - virtual void invalidate(MemRegion mr) = 0; 1.23 + // Causes all refs in "mr" to be assumed to be modified. If "whole_heap" 1.24 + // is true, the caller asserts that the entire heap is being invalidated, 1.25 + // which may admit an optimized implementation for some barriers. 1.26 + virtual void invalidate(MemRegion mr, bool whole_heap = false) = 0; 1.27 1.28 // The caller guarantees that "mr" contains no references. (Perhaps it's 1.29 // objects have been moved elsewhere.)