hotspot/src/share/vm/gc/parallel/mutableSpace.cpp
changeset 46620 750c6edff33b
parent 46619 a3919f5e8d2b
child 46625 edefffab74e2
equal deleted inserted replaced
46619:a3919f5e8d2b 46620:750c6edff33b
    42 }
    42 }
    43 
    43 
    44 void MutableSpace::numa_setup_pages(MemRegion mr, bool clear_space) {
    44 void MutableSpace::numa_setup_pages(MemRegion mr, bool clear_space) {
    45   if (!mr.is_empty()) {
    45   if (!mr.is_empty()) {
    46     size_t page_size = UseLargePages ? alignment() : os::vm_page_size();
    46     size_t page_size = UseLargePages ? alignment() : os::vm_page_size();
    47     HeapWord *start = (HeapWord*)round_to((intptr_t) mr.start(), page_size);
    47     HeapWord *start = align_up(mr.start(), page_size);
    48     HeapWord *end =  (HeapWord*)round_down((intptr_t) mr.end(), page_size);
    48     HeapWord *end =   align_down(mr.end(), page_size);
    49     if (end > start) {
    49     if (end > start) {
    50       size_t size = pointer_delta(end, start, sizeof(char));
    50       size_t size = pointer_delta(end, start, sizeof(char));
    51       if (clear_space) {
    51       if (clear_space) {
    52         // Prefer page reallocation to migration.
    52         // Prefer page reallocation to migration.
    53         os::free_memory((char*)start, size, page_size);
    53         os::free_memory((char*)start, size, page_size);