10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #ifndef SHARE_VM_GC_SHARED_CARDTABLEMODREFBS_HPP
26 #define SHARE_VM_GC_SHARED_CARDTABLEMODREFBS_HPP
27
28 #include "gc/shared/modRefBarrierSet.hpp"
29 #include "oops/oop.hpp"
30
31 // This kind of "BarrierSet" allows a "CollectedHeap" to detect and
32 // enumerate ref fields that have been modified (since the last
33 // enumeration.)
34
35 // As it currently stands, this barrier is *imprecise*: when a ref field in
36 // an object "o" is modified, the card table entry for the card containing
37 // the head of "o" is dirtied, not necessarily the card containing the
38 // modified field itself. For object arrays, however, the barrier *is*
39 // precise; only the card containing the modified element is dirtied.
40 // Closures used to scan dirty cards should take these
41 // considerations into account.
42
43 class CardTableModRefBS: public ModRefBarrierSet {
44 // Some classes get to look at some private stuff.
45 friend class VMStructs;
46 protected:
47
48 enum CardValues {
49 clean_card = -1,
|
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #ifndef SHARE_VM_GC_SHARED_CARDTABLEMODREFBS_HPP
26 #define SHARE_VM_GC_SHARED_CARDTABLEMODREFBS_HPP
27
28 #include "gc/shared/modRefBarrierSet.hpp"
29 #include "oops/oop.hpp"
30 #include "utilities/align.hpp"
31
32 // This kind of "BarrierSet" allows a "CollectedHeap" to detect and
33 // enumerate ref fields that have been modified (since the last
34 // enumeration.)
35
36 // As it currently stands, this barrier is *imprecise*: when a ref field in
37 // an object "o" is modified, the card table entry for the card containing
38 // the head of "o" is dirtied, not necessarily the card containing the
39 // modified field itself. For object arrays, however, the barrier *is*
40 // precise; only the card containing the modified element is dirtied.
41 // Closures used to scan dirty cards should take these
42 // considerations into account.
43
44 class CardTableModRefBS: public ModRefBarrierSet {
45 // Some classes get to look at some private stuff.
46 friend class VMStructs;
47 protected:
48
49 enum CardValues {
50 clean_card = -1,
|