diff options
author | Markus Metzger <mmetzger@sourceware.org> | 2013-03-11 08:48:38 +0000 |
---|---|---|
committer | Markus Metzger <mmetzger@sourceware.org> | 2013-03-11 08:48:38 +0000 |
commit | 67c86d068313124e6c73e6ec0294866fc0471268 (patch) | |
tree | 9e5341abbbf171cda7556c2d963a7bb7ba7ef58f /gdb/target.h | |
parent | 7c1687a9661c460fac39e57a451a90c5f48213d9 (diff) | |
download | gdb-67c86d068313124e6c73e6ec0294866fc0471268.zip gdb-67c86d068313124e6c73e6ec0294866fc0471268.tar.gz gdb-67c86d068313124e6c73e6ec0294866fc0471268.tar.bz2 |
Add a command to provide a disassembly of the execution trace log.
gdb/
* target.h (target_ops) <to_insn_history, to_insn_history_from,
to_insn_history_range>: New fields.
(target_insn_history): New.
(target_insn_history_from): New.
(target_insn_history_range): New.
* target.c (target_insn_history): New.
(target_insn_history_from): New.
(target_insn_history_range): New.
* record.c: Include cli/cli-utils.h, disasm.h, ctype.h.
(record_insn_history_size): New.
(get_insn_number): New.
(get_context_size): New.
(no_chunk): New.
(get_insn_history_modifiers): New.
(cmd_record_insn_history): New.
(_initialize_record): Add "set/show record instruction-history-size"
command. Add "record instruction-history" command.
Diffstat (limited to 'gdb/target.h')
-rw-r--r-- | gdb/target.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/gdb/target.h b/gdb/target.h index adf9f05..32c434b 100644 --- a/gdb/target.h +++ b/gdb/target.h @@ -906,6 +906,22 @@ struct target_ops /* Go to a specific location in the recorded execution trace. */ void (*to_goto_record) (ULONGEST insn); + /* Disassemble SIZE instructions in the recorded execution trace from + the current position. + If SIZE < 0, disassemble abs (SIZE) preceding instructions; otherwise, + disassemble SIZE succeeding instructions. */ + void (*to_insn_history) (int size, int flags); + + /* Disassemble SIZE instructions in the recorded execution trace around + FROM. + If SIZE < 0, disassemble abs (SIZE) instructions before FROM; otherwise, + disassemble SIZE instructions after FROM. */ + void (*to_insn_history_from) (ULONGEST from, int size, int flags); + + /* Disassemble a section of the recorded execution trace from instruction + BEGIN (inclusive) to instruction END (exclusive). */ + void (*to_insn_history_range) (ULONGEST begin, ULONGEST end, int flags); + int to_magic; /* Need sub-structure for target machine related rather than comm related? */ @@ -1997,4 +2013,13 @@ extern void target_goto_record_end (void); /* See to_goto_record in struct target_ops. */ extern void target_goto_record (ULONGEST insn); +/* See to_insn_history. */ +extern void target_insn_history (int size, int flags); + +/* See to_insn_history_from. */ +extern void target_insn_history_from (ULONGEST from, int size, int flags); + +/* See to_insn_history_range. */ +extern void target_insn_history_range (ULONGEST begin, ULONGEST end, int flags); + #endif /* !defined (TARGET_H) */ |