X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=thread.h;h=3a059b5f8615c76f531bfbf9e94252351058e3bb;hb=4f8ea571d59902220616f04ae08685631ed3e685;hp=241b15ee935950b9e12cc05de6f5e222f428e6d3;hpb=acde74e1470244c2d6e7d36e1cddcb699d9ab106;p=p5sagit%2Fp5-mst-13.2.git diff --git a/thread.h b/thread.h index 241b15e..3a059b5 100644 --- a/thread.h +++ b/thread.h @@ -1,6 +1,6 @@ /* thread.h * - * Copyright (C) 1999, 2000, 2001, 2002, 2004, 2005, 2006, + * Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, * by Larry Wall and others * * You may distribute under the terms of either the GNU General Public @@ -98,6 +98,15 @@ # define THREAD_CREATE_NEEDS_STACK (32*1024) #endif +#ifdef __VMS + /* Default is 1024 on VAX, 8192 otherwise */ +# ifdef __ia64 +# define THREAD_CREATE_NEEDS_STACK (48*1024) +# else +# define THREAD_CREATE_NEEDS_STACK (32*1024) +# endif +#endif + #ifdef I_MACH_CTHREADS /* cthreads interface */ @@ -151,7 +160,7 @@ #define THREAD_RET_CAST(x) ((any_t) x) #define DETACH(t) cthread_detach(t->self) -#define JOIN(t, avp) (*(avp) = (AV *)cthread_join(t->self)) +#define JOIN(t, avp) (*(avp) = MUTABLE_AV(cthread_join(t->self))) #define PERL_SET_CONTEXT(t) cthread_set_data(cthread_self(), t) #define PERL_GET_CONTEXT cthread_data(cthread_self()) @@ -333,8 +342,7 @@ #ifndef ALLOC_THREAD_KEY # define ALLOC_THREAD_KEY \ STMT_START { \ - int _eC_; \ - if ((_eC_ = pthread_key_create(&PL_thr_key, 0))) { \ + if (pthread_key_create(&PL_thr_key, 0)) { \ write(2, STR_WITH_LEN("panic: pthread_key_create failed\n")); \ exit(1); \ } \ @@ -468,3 +476,13 @@ #ifndef INIT_THREADS # define INIT_THREADS NOOP #endif + +/* + * Local variables: + * c-indentation-style: bsd + * c-basic-offset: 4 + * indent-tabs-mode: t + * End: + * + * ex: set ts=8 sts=4 sw=4 noet: + */