mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* .gdbinit (iseq): added.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22290 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
36dcff1cf5
commit
2a2cc2e9c4
1 changed files with 26 additions and 3 deletions
29
.gdbinit
29
.gdbinit
|
@ -1,6 +1,3 @@
|
||||||
if dummy_gdb_enums.special_consts
|
|
||||||
end
|
|
||||||
|
|
||||||
define rp
|
define rp
|
||||||
if (VALUE)$arg0 & RUBY_FIXNUM_FLAG
|
if (VALUE)$arg0 & RUBY_FIXNUM_FLAG
|
||||||
printf "FIXNUM: %ld\n", $arg0 >> 1
|
printf "FIXNUM: %ld\n", $arg0 >> 1
|
||||||
|
@ -558,3 +555,29 @@ end
|
||||||
define rb_backtrace
|
define rb_backtrace
|
||||||
call rb_backtrace()
|
call rb_backtrace()
|
||||||
end
|
end
|
||||||
|
|
||||||
|
define iseq
|
||||||
|
if $arg0->type == ISEQ_ELEMENT_NONE
|
||||||
|
echo [none]\n
|
||||||
|
end
|
||||||
|
if $arg0->type == ISEQ_ELEMENT_LABEL
|
||||||
|
print *(LABEL*)$arg0
|
||||||
|
end
|
||||||
|
if $arg0->type == ISEQ_ELEMENT_INSN
|
||||||
|
print *(INSN*)$arg0
|
||||||
|
if ((INSN*)$arg0)->insn_id != YARVINSN_jump
|
||||||
|
set $i = 0
|
||||||
|
set $operand_size = ((INSN*)$arg0)->operand_size
|
||||||
|
set $operands = ((INSN*)$arg0)->operands
|
||||||
|
while $i < $operand_size
|
||||||
|
rp $operands[$i++]
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if $arg0->type == ISEQ_ELEMENT_ADJUST
|
||||||
|
print *(ADJUST*)$arg0
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if dummy_gdb_enums.special_consts
|
||||||
|
end
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue