src/share/vm/memory/referenceProcessor.hpp

changeset 3117
eca1193ca245
parent 3115
c2bf0120ee5d
child 3175
4dfb2df418f2
     1.1 --- a/src/share/vm/memory/referenceProcessor.hpp	Wed Sep 07 15:00:13 2011 -0700
     1.2 +++ b/src/share/vm/memory/referenceProcessor.hpp	Wed Sep 07 13:55:42 2011 -0700
     1.3 @@ -52,6 +52,8 @@
     1.4  
     1.5  class ReferenceProcessor : public CHeapObj {
     1.6   protected:
     1.7 +  // Compatibility with pre-4965777 JDK's
     1.8 +  static bool _pending_list_uses_discovered_field;
     1.9    MemRegion   _span; // (right-open) interval of heap
    1.10                       // subject to wkref discovery
    1.11    bool        _discovering_refs;      // true when discovery enabled
    1.12 @@ -111,7 +113,6 @@
    1.13      return _current_soft_ref_policy;
    1.14    }
    1.15  
    1.16 - public:
    1.17    // Process references with a certain reachability level.
    1.18    void process_discovered_reflist(DiscoveredList               refs_lists[],
    1.19                                    ReferencePolicy*             policy,
    1.20 @@ -297,6 +298,13 @@
    1.21    bool discovery_is_atomic() const { return _discovery_is_atomic; }
    1.22    void set_atomic_discovery(bool atomic) { _discovery_is_atomic = atomic; }
    1.23  
    1.24 +  // whether the JDK in which we are embedded is a pre-4965777 JDK,
    1.25 +  // and thus whether or not it uses the discovered field to chain
    1.26 +  // the entries in the pending list.
    1.27 +  static bool pending_list_uses_discovered_field() {
    1.28 +    return _pending_list_uses_discovered_field;
    1.29 +  }
    1.30 +
    1.31    // whether discovery is done by multiple threads same-old-timeously
    1.32    bool discovery_is_mt() const { return _discovery_is_mt; }
    1.33    void set_mt_discovery(bool mt) { _discovery_is_mt = mt; }

mercurial