From d50483df23383caf098c23c25c133f4eefca5917 Mon Sep 17 00:00:00 2001 From: ko1 Date: Fri, 28 Sep 2012 04:05:36 +0000 Subject: * vm_core.h: remove rb_control_frame_t::bp (bp: base pointer). `bp' can be calculate by `sp' (stack pointer) of previous frame. Now, `bp_check' field is remained for debug. You can eliminate this field by setting VM_DEBUG_BP_CHECK as 0. * vm_insnhelper.c (vm_base_ptr): add `vm_base_ptr(cfp). This function calculates base pointer from cfp. * vm_insnhelper.c (vm_setup_method): push `recv' value on top of value stack (before method parameters). This change is for keeping consistency with normal method dispatch. * insns.def: fix to use vm_base_ptr(). * vm.c (vm_exec): ditto. * vm_dump.c: remove `bp' related dumps. * cont.c (fiber_init): fix to check VM_DEBUG_BP_CHECK. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37043 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- cont.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'cont.c') diff --git a/cont.c b/cont.c index 548b163f7b..9cac2682df 100644 --- a/cont.c +++ b/cont.c @@ -1061,7 +1061,9 @@ fiber_init(VALUE fibval, VALUE proc) th->cfp--; th->cfp->pc = 0; th->cfp->sp = th->stack + 1; - th->cfp->bp = 0; +#if VM_DEBUG_BP_CHECK + th->cfp->bp_check = 0; +#endif th->cfp->ep = th->stack; *th->cfp->ep = VM_ENVVAL_BLOCK_PTR(0); th->cfp->self = Qnil; -- cgit v1.2.3