mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 19:14:38 +02:00
6624765: Guarantee failure "Unexpected dirty card found"
In verification take into account partial coverage of a region by a card and expansion of the card table. Reviewed-by: ysr, apetrusenko
This commit is contained in:
parent
41895dc06d
commit
38fdc8ab98
6 changed files with 32 additions and 15 deletions
|
@ -556,10 +556,16 @@ void CardTableRS::verify() {
|
|||
}
|
||||
|
||||
|
||||
void CardTableRS::verify_empty(MemRegion mr) {
|
||||
void CardTableRS::verify_aligned_region_empty(MemRegion mr) {
|
||||
if (!mr.is_empty()) {
|
||||
jbyte* cur_entry = byte_for(mr.start());
|
||||
jbyte* limit = byte_after(mr.last());
|
||||
// The region mr may not start on a card boundary so
|
||||
// the first card may reflect a write to the space
|
||||
// just prior to mr.
|
||||
if (!is_aligned(mr.start())) {
|
||||
cur_entry++;
|
||||
}
|
||||
for (;cur_entry < limit; cur_entry++) {
|
||||
guarantee(*cur_entry == CardTableModRefBS::clean_card,
|
||||
"Unexpected dirty card found");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue