* thread_pthread.c (RUBY_STACK_MIN, RUBY_STACK_SPACE): delay for
platforms where PTHREAD_STACK_MIN is not compile time constant. [ruby-dev:39751] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25889 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
5a7c9df5b5
commit
a80eb26a18
@ -1,3 +1,9 @@
|
|||||||
|
Mon Nov 23 16:06:53 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* thread_pthread.c (RUBY_STACK_MIN, RUBY_STACK_SPACE): delay for
|
||||||
|
platforms where PTHREAD_STACK_MIN is not compile time constant.
|
||||||
|
[ruby-dev:39751]
|
||||||
|
|
||||||
Mon Nov 23 11:26:45 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Mon Nov 23 11:26:45 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* dln.c (dln_find_1): removed duplication.
|
* dln.c (dln_find_1): removed duplication.
|
||||||
|
@ -463,16 +463,18 @@ enum {
|
|||||||
#else
|
#else
|
||||||
RUBY_STACK_MIN_LIMIT = 512 * 1024, /* 512KB */
|
RUBY_STACK_MIN_LIMIT = 512 * 1024, /* 512KB */
|
||||||
#endif
|
#endif
|
||||||
RUBY_STACK_MIN = (
|
RUBY_STACK_SPACE_LIMIT = 1024 * 1024
|
||||||
#ifdef PTHREAD_STACK_MIN
|
|
||||||
(RUBY_STACK_MIN_LIMIT < PTHREAD_STACK_MIN) ? PTHREAD_STACK_MIN * 2 :
|
|
||||||
#endif
|
|
||||||
RUBY_STACK_MIN_LIMIT),
|
|
||||||
RUBY_STACK_SPACE_LIMIT = 1024 * 1024,
|
|
||||||
RUBY_STACK_SPACE = (RUBY_STACK_MIN/5 > RUBY_STACK_SPACE_LIMIT ?
|
|
||||||
RUBY_STACK_SPACE_LIMIT : RUBY_STACK_MIN/5)
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef PTHREAD_STACK_MIN
|
||||||
|
#define RUBY_STACK_MIN ((RUBY_STACK_MIN_LIMIT < PTHREAD_STACK_MIN) ? \
|
||||||
|
PTHREAD_STACK_MIN * 2 : RUBY_STACK_MIN_LIMIT)
|
||||||
|
#else
|
||||||
|
#define RUBY_STACK_MIN (RUBY_STACK_MIN_LIMIT)
|
||||||
|
#endif
|
||||||
|
#define RUBY_STACK_SPACE (RUBY_STACK_MIN/5 > RUBY_STACK_SPACE_LIMIT ? \
|
||||||
|
RUBY_STACK_SPACE_LIMIT : RUBY_STACK_MIN/5)
|
||||||
|
|
||||||
static int
|
static int
|
||||||
native_thread_create(rb_thread_t *th)
|
native_thread_create(rb_thread_t *th)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user