Print this page
rev 3640 : 7200261: G1: Liveness counting inconsistencies during marking verification
Summary: The clipping code in the routine that sets the bits for a range of cards, in the liveness accounting verification code was incorrect. It set all the bits in the card bitmap from the given starting index which would lead to spurious marking verification failures.
Reviewed-by:
* * *
[mq]: code-review-comments

Split Close
Expand all
Collapse all
          --- old/src/share/vm/gc_implementation/g1/concurrentMark.hpp
          +++ new/src/share/vm/gc_implementation/g1/concurrentMark.hpp
↓ open down ↓ 798 lines elided ↑ open up ↑
 799  799    bool verbose_low() {
 800  800      return _MARKING_VERBOSE_ && _verbose_level >= low_verbose;
 801  801    }
 802  802    bool verbose_medium() {
 803  803      return _MARKING_VERBOSE_ && _verbose_level >= medium_verbose;
 804  804    }
 805  805    bool verbose_high() {
 806  806      return _MARKING_VERBOSE_ && _verbose_level >= high_verbose;
 807  807    }
 808  808  
 809      -  // Counting data structure accessors
      809 +  // Liveness counting
      810 +
      811 +  // Utility routine to set an exclusive range of cards on the given
      812 +  // card liveness bitmap
      813 +  inline void set_card_bitmap_range(BitMap* card_bm,
      814 +                                    BitMap::idx_t start_idx,
      815 +                                    BitMap::idx_t end_idx,
      816 +                                    bool is_par);
 810  817  
 811  818    // Returns the card number of the bottom of the G1 heap.
 812  819    // Used in biasing indices into accounting card bitmaps.
 813  820    intptr_t heap_bottom_card_num() const {
 814  821      return _heap_bottom_card_num;
 815  822    }
 816  823  
 817  824    // Returns the card bitmap for a given task or worker id.
 818  825    BitMap* count_card_bitmap_for(uint worker_id) {
 819  826      assert(0 <= worker_id && worker_id < _max_task_num, "oob");
↓ open down ↓ 409 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX