585 // we see the up-to-date region type here. |
585 // we see the up-to-date region type here. |
586 if (!r->is_old_or_humongous()) { |
586 if (!r->is_old_or_humongous()) { |
587 return; |
587 return; |
588 } |
588 } |
589 |
589 |
590 // While we are processing RSet buffers during the collection, we |
|
591 // actually don't want to scan any cards on the collection set, |
|
592 // since we don't want to update remembered sets with entries that |
|
593 // point into the collection set, given that live objects from the |
|
594 // collection set are about to move and such entries will be stale |
|
595 // very soon. This change also deals with a reliability issue which |
|
596 // involves scanning a card in the collection set and coming across |
|
597 // an array that was being chunked and looking malformed. Note, |
|
598 // however, that if evacuation fails, we have to scan any objects |
|
599 // that were not moved and create any missing entries. |
|
600 if (r->in_collection_set()) { |
|
601 return; |
|
602 } |
|
603 |
|
604 // The result from the hot card cache insert call is either: |
590 // The result from the hot card cache insert call is either: |
605 // * pointer to the current card |
591 // * pointer to the current card |
606 // (implying that the current card is not 'hot'), |
592 // (implying that the current card is not 'hot'), |
607 // * null |
593 // * null |
608 // (meaning we had inserted the card ptr into the "hot" card cache, |
594 // (meaning we had inserted the card ptr into the "hot" card cache, |
623 start = _ct->addr_for(card_ptr); |
609 start = _ct->addr_for(card_ptr); |
624 r = _g1->heap_region_containing(start); |
610 r = _g1->heap_region_containing(start); |
625 |
611 |
626 // Check whether the region formerly in the cache should be |
612 // Check whether the region formerly in the cache should be |
627 // ignored, as discussed earlier for the original card. The |
613 // ignored, as discussed earlier for the original card. The |
628 // region could have been freed while in the cache. The cset is |
614 // region could have been freed while in the cache. |
629 // not relevant here, since we're in concurrent phase. |
|
630 if (!r->is_old_or_humongous()) { |
615 if (!r->is_old_or_humongous()) { |
631 return; |
616 return; |
632 } |
617 } |
633 } // Else we still have the original card. |
618 } // Else we still have the original card. |
634 } |
619 } |