mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* cont.c: rename FIBER_STACK_SIZE to FIBER_VM_STACK_SIZE.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13270 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
2d888a8f33
commit
c2a734ea99
2 changed files with 7 additions and 2 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
Sat Aug 25 17:48:51 2007 Koichi Sasada <ko1@atdot.net>
|
||||||
|
|
||||||
|
* cont.c: rename FIBER_STACK_SIZE to FIBER_VM_STACK_SIZE.
|
||||||
|
|
||||||
Sat Aug 25 17:05:05 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Sat Aug 25 17:05:05 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* io.c (swallow): removed condition using an unset variable.
|
* io.c (swallow): removed condition using an unset variable.
|
||||||
|
|
5
cont.c
5
cont.c
|
@ -469,7 +469,7 @@ rb_cont_call(int argc, VALUE *argv, VALUE contval)
|
||||||
/* fiber */
|
/* fiber */
|
||||||
/*********/
|
/*********/
|
||||||
|
|
||||||
#define FIBER_STACK_SIZE (4 * 1024)
|
#define FIBER_VM_STACK_SIZE (4 * 1024)
|
||||||
|
|
||||||
VALUE
|
VALUE
|
||||||
rb_fiber_new(VALUE (*func)(ANYARGS), VALUE obj)
|
rb_fiber_new(VALUE (*func)(ANYARGS), VALUE obj)
|
||||||
|
@ -489,7 +489,7 @@ rb_fiber_s_new(VALUE self)
|
||||||
cont->vm_stack = 0;
|
cont->vm_stack = 0;
|
||||||
|
|
||||||
th->stack = 0;
|
th->stack = 0;
|
||||||
th->stack_size = FIBER_STACK_SIZE;
|
th->stack_size = FIBER_VM_STACK_SIZE;
|
||||||
th->stack = ALLOC_N(VALUE, th->stack_size);
|
th->stack = ALLOC_N(VALUE, th->stack_size);
|
||||||
|
|
||||||
th->cfp = (void *)(th->stack + th->stack_size);
|
th->cfp = (void *)(th->stack + th->stack_size);
|
||||||
|
@ -650,6 +650,7 @@ fiber_switch(VALUE fib, int argc, VALUE *argv, int is_resume)
|
||||||
if (is_resume) {
|
if (is_resume) {
|
||||||
cont->prev = rb_fiber_current();
|
cont->prev = rb_fiber_current();
|
||||||
}
|
}
|
||||||
|
|
||||||
cont->value = make_passing_arg(argc, argv);
|
cont->value = make_passing_arg(argc, argv);
|
||||||
|
|
||||||
if ((value = cont_store(cont)) == Qundef) {
|
if ((value = cont_store(cont)) == Qundef) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue