Mercurial > hg > graal-compiler
comparison src/share/vm/gc_implementation/g1/g1CollectedHeap.cpp @ 4014:bf2d2b8b1726
7095243: Disambiguate ReferenceProcessor::_discoveredSoftRefs
Summary: Add a new, separate, pointer to the base of the array of discovered reference lists and use this new pointer in places where we iterate over the entire array.
Reviewed-by: ysr, brutisso
author | johnc |
---|---|
date | Mon, 17 Oct 2011 09:57:41 -0700 |
parents | 074f0252cc13 |
children | c6a6e936dc68 |
comparison
equal
deleted
inserted
replaced
4013:074f0252cc13 | 4014:bf2d2b8b1726 |
---|---|
5066 assert(0 <= i && i < limit, "sanity"); | 5066 assert(0 <= i && i < limit, "sanity"); |
5067 assert(!rp->discovery_is_atomic(), "check this code"); | 5067 assert(!rp->discovery_is_atomic(), "check this code"); |
5068 | 5068 |
5069 // Select discovered lists [i, i+stride, i+2*stride,...,limit) | 5069 // Select discovered lists [i, i+stride, i+2*stride,...,limit) |
5070 for (int idx = i; idx < limit; idx += stride) { | 5070 for (int idx = i; idx < limit; idx += stride) { |
5071 DiscoveredList& ref_list = rp->discovered_soft_refs()[idx]; | 5071 DiscoveredList& ref_list = rp->discovered_refs()[idx]; |
5072 | 5072 |
5073 DiscoveredListIterator iter(ref_list, &keep_alive, &always_alive); | 5073 DiscoveredListIterator iter(ref_list, &keep_alive, &always_alive); |
5074 while (iter.has_next()) { | 5074 while (iter.has_next()) { |
5075 // Since discovery is not atomic for the CM ref processor, we | 5075 // Since discovery is not atomic for the CM ref processor, we |
5076 // can see some null referent objects. | 5076 // can see some null referent objects. |