-
Bug
-
Resolution: Fixed
-
P3
-
1.2.2_13
-
15
-
sparc
-
solaris_8
Customer is seeing crashes due to stack overflow. Need to re analyse the
current buffer zone:
src/solaris/hpi/native_threads/include/threads_md.h
/*
* sysThreadCheckStack() being a function call is unfortunate, as it
* takes stack space to do, but that is weakly accounted for by the
* previous stack redzone. In general, where we can't predict stack
* use by C, thread stack overflow checking doesn't really work.
*
* The value of STACK_REDZONE determines how much room must remain on the
* stack for sysThreadCheckStack() to declare success.
*
* At first glance it might appear that sysThreadCheckStack could be
* implemented in terms of sysThreadCheckStack0. However, that would add
* another stack frame and distort the check.
*
* Note also that these functions rely on local variables and parameters being
* allocated on the stack, so that taking their address reveals how deep the
* stack has grown.
*/
#ifdef DEBUG
#define STACK_REDZONE 0x1800 /* should be a multiple of 1K, see JITPass2.c */
#else
#define STACK_REDZONE 0x1000 /* should be at most 4k, see JITPass2.c */
#endif
current buffer zone:
src/solaris/hpi/native_threads/include/threads_md.h
/*
* sysThreadCheckStack() being a function call is unfortunate, as it
* takes stack space to do, but that is weakly accounted for by the
* previous stack redzone. In general, where we can't predict stack
* use by C, thread stack overflow checking doesn't really work.
*
* The value of STACK_REDZONE determines how much room must remain on the
* stack for sysThreadCheckStack() to declare success.
*
* At first glance it might appear that sysThreadCheckStack could be
* implemented in terms of sysThreadCheckStack0. However, that would add
* another stack frame and distort the check.
*
* Note also that these functions rely on local variables and parameters being
* allocated on the stack, so that taking their address reveals how deep the
* stack has grown.
*/
#ifdef DEBUG
#define STACK_REDZONE 0x1800 /* should be a multiple of 1K, see JITPass2.c */
#else
#define STACK_REDZONE 0x1000 /* should be at most 4k, see JITPass2.c */
#endif