Skip to content

Commit 0b6862e

Browse files
committedFeb 24, 2022
8282348: Remove unused CardTable::dirty_card_iterate
Reviewed-by: kbarrett
1 parent 6fab8a2 commit 0b6862e

File tree

2 files changed

+0
-30
lines changed

2 files changed

+0
-30
lines changed
 

‎src/hotspot/share/gc/shared/cardTable.cpp

-26
Original file line numberDiff line numberDiff line change
@@ -385,32 +385,6 @@ void CardTable::dirty(MemRegion mr) {
385385
memset(first, dirty_card, last-first);
386386
}
387387

388-
// Unlike several other card table methods, dirty_card_iterate()
389-
// iterates over dirty cards ranges in increasing address order.
390-
void CardTable::dirty_card_iterate(MemRegion mr, MemRegionClosure* cl) {
391-
for (int i = 0; i < _cur_covered_regions; i++) {
392-
MemRegion mri = mr.intersection(_covered[i]);
393-
if (!mri.is_empty()) {
394-
CardValue *cur_entry, *next_entry, *limit;
395-
for (cur_entry = byte_for(mri.start()), limit = byte_for(mri.last());
396-
cur_entry <= limit;
397-
cur_entry = next_entry) {
398-
next_entry = cur_entry + 1;
399-
if (*cur_entry == dirty_card) {
400-
size_t dirty_cards;
401-
// Accumulate maximal dirty card range, starting at cur_entry
402-
for (dirty_cards = 1;
403-
next_entry <= limit && *next_entry == dirty_card;
404-
dirty_cards++, next_entry++);
405-
MemRegion cur_cards(addr_for(cur_entry),
406-
dirty_cards*_card_size_in_words);
407-
cl->do_MemRegion(cur_cards);
408-
}
409-
}
410-
}
411-
}
412-
}
413-
414388
MemRegion CardTable::dirty_card_range_after_reset(MemRegion mr,
415389
bool reset,
416390
int reset_val) {

‎src/hotspot/share/gc/shared/cardTable.hpp

-4
Original file line numberDiff line numberDiff line change
@@ -218,10 +218,6 @@ class CardTable: public CHeapObj<mtGC> {
218218

219219
static uintx ct_max_alignment_constraint();
220220

221-
// Apply closure "cl" to the dirty cards containing some part of
222-
// MemRegion "mr".
223-
void dirty_card_iterate(MemRegion mr, MemRegionClosure* cl);
224-
225221
// Return the MemRegion corresponding to the first maximal run
226222
// of dirty cards lying completely within MemRegion mr.
227223
// If reset is "true", then sets those card table entries to the given

0 commit comments

Comments
 (0)
Please sign in to comment.