1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* .gdbinit: follow r55766's VM change.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55997 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
naruse 2016-08-24 07:56:51 +00:00
parent 0022316e96
commit fe5f47a6ee
2 changed files with 22 additions and 14 deletions

View file

@ -976,7 +976,7 @@ define check_method_entry
# get $immeo and $can_be_svar and return $me # get $immeo and $can_be_svar and return $me
set $imemo = (struct RBasic *)$arg0 set $imemo = (struct RBasic *)$arg0
set $can_be_svar = $arg1 set $can_be_svar = $arg1
if $imemo != Qfalse if $imemo != RUBY_Qfalse
set $type = ($imemo->flags >> 12) & 0x07 set $type = ($imemo->flags >> 12) & 0x07
if $type == imemo_ment if $type == imemo_ment
set $me = (rb_callable_method_entry_t *)$imemo set $me = (rb_callable_method_entry_t *)$imemo
@ -993,7 +993,7 @@ define output_id
set $id = $arg0 set $id = $arg0
# rb_id_to_serial # rb_id_to_serial
if $id > tLAST_OP_ID if $id > tLAST_OP_ID
set $serial = (rb_id_serial_t)($id >> ID_SCOPE_SHIFT) set $serial = (rb_id_serial_t)($id >> RUBY_ID_SCOPE_SHIFT)
else else
set $serial = (rb_id_serial_t)$id set $serial = (rb_id_serial_t)$id
end end
@ -1011,7 +1011,7 @@ define output_id
if $idx < $idslen if $idx < $idslen
set $t = 0 set $t = 0
set $ary = (struct RArray *)$idsptr[$idx] set $ary = (struct RArray *)$idsptr[$idx]
if $ary != Qnil if $ary != RUBY_Qnil
set $flags = $ary->basic.flags set $flags = $ary->basic.flags
if ($flags & RUBY_FL_USER1) if ($flags & RUBY_FL_USER1)
set $aryptr = $ary->as.ary set $aryptr = $ary->as.ary
@ -1048,21 +1048,25 @@ define rb_ps_thread
printf "???.rb:???:in `???'\n" printf "???.rb:???:in `???'\n"
end end
else else
# if ($cfp->flag & VM_FRAME_MAGIC_MASK) == VM_FRAME_MAGIC_CFUNC # if VM_FRAME_TYPE($cfp->flag) == VM_FRAME_MAGIC_CFUNC
if ($cfp->flag & 255) == 0x61 set $ep = $cfp->ep
#define VM_ENVVAL_BLOCK_PTR_FLAG 0x02 if ($ep[0] & 0xffff0001) == 0x55550001
#define VM_EP_PREV_EP(ep) ((VALUE *)GC_GUARDED_PTR_REF((ep)[0])) #define VM_ENV_FLAG_LOCAL 0x02
set $ep = $cfp->ep #define VM_ENV_PREV_EP(ep) GC_GUARDED_PTR_REF(ep[VM_ENV_DATA_INDEX_SPECVAL])
set $me = NULL set $me = 0
while ($ep[0] & 0x02) != 0 set $env_specval = $ep[-1]
check_method_entry $ep[-1] 0 set $env_me_cref = $ep[-2]
if $me != NULL while ($env_specval & 0x02) != 0
check_method_entry $env_me_cref 0
if $me != 0
loop_break loop_break
end end
set $ep = $ep[0] set $ep = $ep[0]
set $env_specval = $ep[-1]
set $env_me_cref = $ep[-2]
end end
if $me == NULL if $me == 0
check_method_entry $ep[-1] 1 check_method_entry $env_me_cref 1
end end
set print symbol-filename on set print symbol-filename on
output/a $me->def->body.cfunc.func output/a $me->def->body.cfunc.func

View file

@ -1,3 +1,7 @@
Wed Aug 24 16:56:26 2016 NARUSE, Yui <naruse@ruby-lang.org>
* .gdbinit: follow r55766's VM change.
Wed Aug 24 12:57:56 2016 Nobuyoshi Nakada <nobu@ruby-lang.org> Wed Aug 24 12:57:56 2016 Nobuyoshi Nakada <nobu@ruby-lang.org>
* object.c (rb_mod_initialize, rb_class_initialize): [DOC] these * object.c (rb_mod_initialize, rb_class_initialize): [DOC] these