diff options
author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-09 05:56:00 +0000 |
---|---|---|
committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-12-09 05:56:00 +0000 |
commit | 3923d7f420d1cbcad2b7fd781ffeb389d3151d07 (patch) | |
tree | 24c719859351e4aa9f0dedb644af91cba330c235 /vm.c | |
parent | 3a8f7f1d7f3f1b66f47c37b230bc9c53cbdae250 (diff) | |
download | ruby-3923d7f420d1cbcad2b7fd781ffeb389d3151d07.tar.gz |
* vm.c (rb_thread_mark): use rb_gc_mark_maybe() for
VM stack specified by mark_stack_len.
* insnhelper.ci: clear vm stack extended by opt value.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'vm.c')
-rw-r--r-- | vm.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -1616,14 +1616,15 @@ rb_thread_mark(void *ptr) th = ptr; if (th->stack) { VALUE *p = th->stack; - VALUE *sp = th->cfp->sp + th->mark_stack_len; + VALUE *sp = th->cfp->sp; rb_control_frame_t *cfp = th->cfp; - rb_control_frame_t *limit_cfp = - (void *)(th->stack + th->stack_size); + rb_control_frame_t *limit_cfp = (void *)(th->stack + th->stack_size); while (p < sp) { rb_gc_mark(*p++); } + rb_gc_mark_locations(p, p + th->mark_stack_len); + while (cfp != limit_cfp) { rb_gc_mark(cfp->proc); cfp = RUBY_VM_PREVIOUS_CONTROL_FRAME(cfp); |