< prev index next >
src/hotspot/share/gc/z/zMarkStackAllocator.cpp
Print this page
*** 108,119 ****
// Expand
os::commit_memory_or_exit((char*)_end, expand_size, false /* executable */, "Mark stack space");
// Increment top before end to make sure another
// thread can't steal out newly expanded space.
! addr = Atomic::add(size, &_top) - size;
! Atomic::add(expand_size, &_end);
return addr;
}
uintptr_t ZMarkStackSpace::alloc(size_t size) {
--- 108,119 ----
// Expand
os::commit_memory_or_exit((char*)_end, expand_size, false /* executable */, "Mark stack space");
// Increment top before end to make sure another
// thread can't steal out newly expanded space.
! addr = Atomic::add(&_top, size) - size;
! Atomic::add(&_end, expand_size);
return addr;
}
uintptr_t ZMarkStackSpace::alloc(size_t size) {
< prev index next >