8025305: Cleanup CardTableModRefBS usage in G1

Move some G1 specific code from CardTableModRefBS to G1SATBCardTableModRefBS.

Reviewed-by: brutisso, tschatzl, ehelin
This commit is contained in:
Mikael Gerdin 2013-09-24 14:46:29 +02:00
parent b23e1e15a3
commit b8363e6615
12 changed files with 90 additions and 128 deletions

View file

@ -339,34 +339,10 @@ public:
_byte_map[card_index] = dirty_card_val();
}
bool is_card_claimed(size_t card_index) {
jbyte val = _byte_map[card_index];
return (val & (clean_card_mask_val() | claimed_card_val())) == claimed_card_val();
}
void set_card_claimed(size_t card_index) {
jbyte val = _byte_map[card_index];
if (val == clean_card_val()) {
val = (jbyte)claimed_card_val();
} else {
val |= (jbyte)claimed_card_val();
}
_byte_map[card_index] = val;
}
bool claim_card(size_t card_index);
bool is_card_clean(size_t card_index) {
return _byte_map[card_index] == clean_card_val();
}
bool is_card_deferred(size_t card_index) {
jbyte val = _byte_map[card_index];
return (val & (clean_card_mask_val() | deferred_card_val())) == deferred_card_val();
}
bool mark_card_deferred(size_t card_index);
// Card marking array base (adjusted for heap low boundary)
// This would be the 0th element of _byte_map, if the heap started at 0x0.
// But since the heap starts at some higher address, this points to somewhere