hotspot/src/os/windows/vm/os_windows.cpp
changeset 2259 d3c946e7f127
parent 2105 347008ce7984
parent 2254 f13dda645a4b
child 2268 bea8be80ec88
equal deleted inserted replaced
2252:703d28e44a42 2259:d3c946e7f127
  2593 
  2593 
  2594 bool os::can_execute_large_page_memory() {
  2594 bool os::can_execute_large_page_memory() {
  2595   return true;
  2595   return true;
  2596 }
  2596 }
  2597 
  2597 
  2598 char* os::reserve_memory_special(size_t bytes) {
  2598 char* os::reserve_memory_special(size_t bytes, char* addr) {
  2599 
  2599 
  2600   if (UseLargePagesIndividualAllocation) {
  2600   if (UseLargePagesIndividualAllocation) {
  2601     if (TracePageSizes && Verbose) {
  2601     if (TracePageSizes && Verbose) {
  2602        tty->print_cr("Reserving large pages individually.");
  2602        tty->print_cr("Reserving large pages individually.");
  2603     }
  2603     }
  2613       // Overflowed.
  2613       // Overflowed.
  2614       warning("Individually allocated large pages failed, "
  2614       warning("Individually allocated large pages failed, "
  2615         "use -XX:-UseLargePagesIndividualAllocation to turn off");
  2615         "use -XX:-UseLargePagesIndividualAllocation to turn off");
  2616       return NULL;
  2616       return NULL;
  2617     }
  2617     }
  2618     p_buf = (char *) VirtualAlloc(NULL,
  2618     p_buf = (char *) VirtualAlloc(addr,
  2619                                  size_of_reserve,  // size of Reserve
  2619                                  size_of_reserve,  // size of Reserve
  2620                                  MEM_RESERVE,
  2620                                  MEM_RESERVE,
  2621                                  PAGE_EXECUTE_READWRITE);
  2621                                  PAGE_EXECUTE_READWRITE);
  2622     // If reservation failed, return NULL
  2622     // If reservation failed, return NULL
  2623     if (p_buf == NULL) return NULL;
  2623     if (p_buf == NULL) return NULL;