comparison src/share/vm/gc_implementation/g1/g1PageBasedVirtualSpace.cpp @ 22973:340ca8812af9

8067469: G1 ignores AlwaysPreTouch Summary: Factor out pretouch code of the various virtual space management classes and use them everywhere including in G1. Reviewed-by: stefank, ehelin, dholmes
author tschatzl
date Thu, 18 Dec 2014 09:37:02 +0100
parents ae52ee069062
children 33e421924c67
comparison
equal deleted inserted replaced
22972:41a855ff6305 22973:340ca8812af9
142 os::commit_memory_or_exit(page_start(start), byte_size_for_pages(size_in_pages), _executable, 142 os::commit_memory_or_exit(page_start(start), byte_size_for_pages(size_in_pages), _executable,
143 err_msg("Failed to commit pages from "SIZE_FORMAT" of length "SIZE_FORMAT, start, size_in_pages)); 143 err_msg("Failed to commit pages from "SIZE_FORMAT" of length "SIZE_FORMAT, start, size_in_pages));
144 } 144 }
145 _committed.set_range(start, end); 145 _committed.set_range(start, end);
146 146
147 if (AlwaysPreTouch) {
148 os::pretouch_memory(page_start(start), page_start(start) + byte_size_for_pages(size_in_pages));
149 }
147 return zero_filled; 150 return zero_filled;
148 } 151 }
149 152
150 void G1PageBasedVirtualSpace::uncommit(uintptr_t start, size_t size_in_pages) { 153 void G1PageBasedVirtualSpace::uncommit(uintptr_t start, size_t size_in_pages) {
151 guarantee(is_area_committed(start, size_in_pages), "checking"); 154 guarantee(is_area_committed(start, size_in_pages), "checking");