Mercurial > hg > graal-jvmci-8
diff src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp @ 3986:65a8ff39a6da
7095194: G1: HeapRegion::GrainBytes, GrainWords, and CardsPerRegion should be size_t
Summary: Declare GrainBytes, GrainWords, and CardsPerRegion as size_t.
Reviewed-by: jcoomes, tonyp, jmasa
author | johnc |
---|---|
date | Wed, 05 Oct 2011 08:44:10 -0700 |
parents | f44782f04dd4 |
children | 5e5d4821bf07 |
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp Mon Sep 12 16:09:50 2011 +0200 +++ b/src/share/vm/gc_implementation/g1/heapRegionRemSet.cpp Wed Oct 05 08:44:10 2011 -0700 @@ -148,7 +148,7 @@ CardIdx_t from_card = (CardIdx_t) hw_offset >> (CardTableModRefBS::card_shift - LogHeapWordSize); - assert(0 <= from_card && from_card < HeapRegion::CardsPerRegion, + assert(0 <= from_card && (size_t)from_card < HeapRegion::CardsPerRegion, "Must be in range."); add_card_work(from_card, par); } @@ -639,7 +639,7 @@ uintptr_t(from_hr->bottom()) >> CardTableModRefBS::card_shift; CardIdx_t card_index = from_card - from_hr_bot_card_index; - assert(0 <= card_index && card_index < HeapRegion::CardsPerRegion, + assert(0 <= card_index && (size_t)card_index < HeapRegion::CardsPerRegion, "Must be in range."); if (G1HRRSUseSparseTable && _sparse_table.add_card(from_hrs_ind, card_index)) { @@ -1066,7 +1066,7 @@ uintptr_t(hr->bottom()) >> CardTableModRefBS::card_shift; assert(from_card >= hr_bot_card_index, "Inv"); CardIdx_t card_index = from_card - hr_bot_card_index; - assert(0 <= card_index && card_index < HeapRegion::CardsPerRegion, + assert(0 <= card_index && (size_t)card_index < HeapRegion::CardsPerRegion, "Must be in range."); return _sparse_table.contains_card(hr_ind, card_index); } @@ -1191,7 +1191,7 @@ _is = Sparse; // Set these values so that we increment to the first region. _coarse_cur_region_index = -1; - _coarse_cur_region_cur_card = (HeapRegion::CardsPerRegion-1);; + _coarse_cur_region_cur_card = (HeapRegion::CardsPerRegion-1); _cur_region_cur_card = 0; @@ -1270,7 +1270,7 @@ bool HeapRegionRemSetIterator::fine_has_next() { return _fine_cur_prt != NULL && - _cur_region_cur_card < (size_t) HeapRegion::CardsPerRegion; + _cur_region_cur_card < HeapRegion::CardsPerRegion; } bool HeapRegionRemSetIterator::has_next(size_t& card_index) {