equal
deleted
inserted
replaced
109 MemoryType type) : |
109 MemoryType type) : |
110 G1RegionToSpaceMapper(rs, actual_size, page_size, alloc_granularity, commit_factor, type), |
110 G1RegionToSpaceMapper(rs, actual_size, page_size, alloc_granularity, commit_factor, type), |
111 _regions_per_page((page_size * commit_factor) / alloc_granularity), _refcounts() { |
111 _regions_per_page((page_size * commit_factor) / alloc_granularity), _refcounts() { |
112 |
112 |
113 guarantee((page_size * commit_factor) >= alloc_granularity, "allocation granularity smaller than commit granularity"); |
113 guarantee((page_size * commit_factor) >= alloc_granularity, "allocation granularity smaller than commit granularity"); |
114 _refcounts.initialize((HeapWord*)rs.base(), (HeapWord*)(rs.base() + align_size_up(rs.size(), page_size)), page_size); |
114 _refcounts.initialize((HeapWord*)rs.base(), (HeapWord*)(rs.base() + align_up(rs.size(), page_size)), page_size); |
115 } |
115 } |
116 |
116 |
117 virtual void commit_regions(uint start_idx, size_t num_regions, WorkGang* pretouch_gang) { |
117 virtual void commit_regions(uint start_idx, size_t num_regions, WorkGang* pretouch_gang) { |
118 size_t const NoPage = ~(size_t)0; |
118 size_t const NoPage = ~(size_t)0; |
119 |
119 |