< prev index next >
src/hotspot/os/windows/os_windows.cpp
Print this page
rev 52365 : [mq]: 8213058
@@ -5555,16 +5555,12 @@
// This is of course only some dodgy assumption, there is no guarantee that the vicinity of
// the previously allocated memory is available for allocation. The only actual failure
// that is reported is when the test tries to allocate at a particular location but gets a
// different valid one. A NULL return value at this point is not considered an error but may
// be legitimate.
-// If -XX:+VerboseInternalVMTests is enabled, print some explanatory messages.
void TestReserveMemorySpecial_test() {
if (!UseLargePages) {
- if (VerboseInternalVMTests) {
- tty->print("Skipping test because large pages are disabled");
- }
return;
}
// save current value of globals
bool old_use_large_pages_individual_allocation = UseLargePagesIndividualAllocation;
bool old_use_numa_interleaving = UseNUMAInterleaving;
@@ -5574,27 +5570,19 @@
// do an allocation at an address selected by the OS to get a good one.
const size_t large_allocation_size = os::large_page_size() * 4;
char* result = os::reserve_memory_special(large_allocation_size, os::large_page_size(), NULL, false);
if (result == NULL) {
- if (VerboseInternalVMTests) {
- tty->print("Failed to allocate control block with size " SIZE_FORMAT ". Skipping remainder of test.",
- large_allocation_size);
- }
} else {
os::release_memory_special(result, large_allocation_size);
// allocate another page within the recently allocated memory area which seems to be a good location. At least
// we managed to get it once.
const size_t expected_allocation_size = os::large_page_size();
char* expected_location = result + os::large_page_size();
char* actual_location = os::reserve_memory_special(expected_allocation_size, os::large_page_size(), expected_location, false);
if (actual_location == NULL) {
- if (VerboseInternalVMTests) {
- tty->print("Failed to allocate any memory at " PTR_FORMAT " size " SIZE_FORMAT ". Skipping remainder of test.",
- expected_location, large_allocation_size);
- }
} else {
// release memory
os::release_memory_special(actual_location, expected_allocation_size);
// only now check, after releasing any memory to avoid any leaks.
assert(actual_location == expected_location,
< prev index next >