Mercurial > hg > graal-jvmci-8
comparison src/os/windows/vm/os_windows.cpp @ 1320:3b3d12e645e7
6929067: Stack guard pages should be removed when thread is detached
Summary: Add code to unmap stack guard area when thread is detached.
Reviewed-by: coleenp, kamg
author | coleenp |
---|---|
date | Fri, 12 Mar 2010 10:42:16 -0500 |
parents | f19bf22685cc |
children | a2ea687fdc7c |
comparison
equal
deleted
inserted
replaced
1292:12d91eb0f579 | 1320:3b3d12e645e7 |
---|---|
2801 | 2801 |
2802 bool os::release_memory(char* addr, size_t bytes) { | 2802 bool os::release_memory(char* addr, size_t bytes) { |
2803 return VirtualFree(addr, 0, MEM_RELEASE) != 0; | 2803 return VirtualFree(addr, 0, MEM_RELEASE) != 0; |
2804 } | 2804 } |
2805 | 2805 |
2806 bool os::create_stack_guard_pages(char* addr, size_t size) { | |
2807 return os::commit_memory(addr, size); | |
2808 } | |
2809 | |
2810 bool os::remove_stack_guard_pages(char* addr, size_t size) { | |
2811 return os::uncommit_memory(addr, size); | |
2812 } | |
2813 | |
2806 // Set protections specified | 2814 // Set protections specified |
2807 bool os::protect_memory(char* addr, size_t bytes, ProtType prot, | 2815 bool os::protect_memory(char* addr, size_t bytes, ProtType prot, |
2808 bool is_committed) { | 2816 bool is_committed) { |
2809 unsigned int p = 0; | 2817 unsigned int p = 0; |
2810 switch (prot) { | 2818 switch (prot) { |