[cmucl-commit] CMUCL commit: src/lisp (x86-validate.h)

Raymond Toy rtoy at common-lisp.net
Sat Dec 18 17:16:48 CET 2010


    Date: Saturday, December 18, 2010 @ 11:16:48
  Author: rtoy
    Path: /project/cmucl/cvsroot/src/lisp

Modified: x86-validate.h

On Darwin, SIGSTKSZ is 128K, not 8K like on most other systems.
Adjust the CONTROL_STACK_SIZE and SIGNAL_STACK_START appropriately. 


----------------+
 x86-validate.h |   13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)


Index: src/lisp/x86-validate.h
diff -u src/lisp/x86-validate.h:1.31 src/lisp/x86-validate.h:1.32
--- src/lisp/x86-validate.h:1.31	Fri May 21 15:26:53 2010
+++ src/lisp/x86-validate.h	Sat Dec 18 11:16:47 2010
@@ -3,7 +3,7 @@
  * This code was written as part of the CMU Common Lisp project at
  * Carnegie Mellon University, and has been placed in the public domain.
  *
- *  $Header: /project/cmucl/cvsroot/src/lisp/x86-validate.h,v 1.31 2010-05-21 19:26:53 rtoy Rel $
+ *  $Header: /project/cmucl/cvsroot/src/lisp/x86-validate.h,v 1.32 2010-12-18 16:16:47 rtoy Exp $
  *
  */
 
@@ -132,10 +132,21 @@
 #define BINDING_STACK_SIZE	(0x07fff000)	/* 128MB - 1 page */
 
 #define CONTROL_STACK_START	(0x40000000)
+#if defined(DARWIN)
+/*
+ * According to /usr/include/sys/signal.h, MINSIGSTKSZ is 32K and
+ * SIGSTKSZ is 128K.  We should account for that appropriately.
+ */
+#define CONTROL_STACK_SIZE	(0x07fdf000)	/* 128MB - SIGSTKSZ - 1 page */
+
+#define SIGNAL_STACK_START	(0x47fe0000)    /* One page past the end of the control stack */
+#define SIGNAL_STACK_SIZE	SIGSTKSZ
+#else
 #define CONTROL_STACK_SIZE	(0x07fd8000)	/* 128MB - SIGSTKSZ */
 
 #define SIGNAL_STACK_START	(0x47fd8000)
 #define SIGNAL_STACK_SIZE	SIGSTKSZ
+#endif
 
 #define DYNAMIC_0_SPACE_START	(SpaceStart_TargetDynamic)
 #ifdef GENCGC


More information about the cmucl-commit mailing list