summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/debug/debughlp.cpp
diff options
context:
space:
mode:
author therealmogminer@gmail.com <therealmogminer@gmail.com>2016-07-14 16:13:52 +0200
committer therealmogminer@gmail.com <therealmogminer@gmail.com>2016-07-14 16:13:52 +0200
commitc643372753b8e5823d2ff5b68475a6b60e0a672d (patch)
treebc66495d9ecdbf7f66ab086b897d39a80f576e70 /src/emu/debug/debughlp.cpp
parentd3dd9f8f95c5ebca51a691c7a6bc915a75276fd8 (diff)
Make loop collation optional for debugger trace and traceover commands
Diffstat (limited to 'src/emu/debug/debughlp.cpp')
-rw-r--r--src/emu/debug/debughlp.cpp47
1 files changed, 29 insertions, 18 deletions
diff --git a/src/emu/debug/debughlp.cpp b/src/emu/debug/debughlp.cpp
index 8d66f59d85a..6f14f4d3e64 100644
--- a/src/emu/debug/debughlp.cpp
+++ b/src/emu/debug/debughlp.cpp
@@ -140,8 +140,8 @@ static const help_item static_help_list[] =
" focus <cpu> -- focuses debugger only on <cpu>\n"
" ignore [<cpu>[,<cpu>[,...]]] -- stops debugging on <cpu>\n"
" observe [<cpu>[,<cpu>[,...]]] -- resumes debugging on <cpu>\n"
- " trace {<filename>|OFF}[,<cpu>[,<action>]] -- trace the given CPU to a file (defaults to active CPU)\n"
- " traceover {<filename>|OFF}[,<cpu>[,<action>]] -- trace the given CPU to a file, but skip subroutines (defaults to active CPU)\n"
+ " trace {<filename>|OFF}[,<cpu>[,<detectloops>[,<action>]]] -- trace the given CPU to a file (defaults to active CPU)\n"
+ " traceover {<filename>|OFF}[,<cpu>[,<detectloops>[,<action>]]] -- trace the given CPU to a file, but skip subroutines (defaults to active CPU)\n"
" traceflush -- flushes all open trace files\n"
},
{
@@ -818,11 +818,14 @@ static const help_item static_help_list[] =
{
"trace",
"\n"
- " trace {<filename>|OFF}[,<cpu>[,<action>]]\n"
+ " trace {<filename>|OFF}[,<cpu>[,<detectloops>[,<action>]]]\n"
"\n"
"Starts or stops tracing of the execution of the specified <cpu>. If <cpu> is omitted, "
"the currently active CPU is specified. When enabling tracing, specify the filename in the "
- "<filename> parameter. To disable tracing, substitute the keyword 'off' for <filename>. If you "
+ "<filename> parameter. To disable tracing, substitute the keyword 'off' for <filename>. "
+ "<detectloops> should be either true or false. If <detectloops> is true or omitted, the trace "
+ "will have loops detected and condensed to a single line. If it is false, the trace will contain "
+ "every opcode as it is executed. If you "
"wish to log additional information on each trace, you can append an <action> parameter which "
"is a command that is executed before each trace is logged. Generally, this is used to include "
"a 'tracelog' command. Note that you may need to embed the action within braces { } in order "
@@ -831,11 +834,14 @@ static const help_item static_help_list[] =
"\n"
"Examples:\n"
"\n"
+ "trace joust.tr\n"
+ " Begin tracing the currently active CPU, logging output to joust.tr.\n"
+ "\n"
"trace dribling.tr,0\n"
" Begin tracing the execution of CPU #0, logging output to dribling.tr.\n"
"\n"
- "trace joust.tr\n"
- " Begin tracing the currently active CPU, logging output to joust.tr.\n"
+ "trace starswep.tr,0,false\n"
+ " Begin tracing the execution of CPU #0, logging output to starswep.tr, with loop detection disabled.\n"
"\n"
"trace >>pigskin.tr\n"
" Begin tracing the currently active CPU, appending log output to pigskin.tr.\n"
@@ -843,39 +849,44 @@ static const help_item static_help_list[] =
"trace off,0\n"
" Turn off tracing on CPU #0.\n"
"\n"
- "trace asteroid.tr,0,{tracelog \"A=%02X \",a}\n"
+ "trace asteroid.tr,0,true,{tracelog \"A=%02X \",a}\n"
" Begin tracing the execution of CPU #0, logging output to asteroid.tr. Before each line, "
"output A=<aval> to the tracelog.\n"
},
{
"traceover",
"\n"
- " traceover {<filename>|OFF}[,<cpu>[,<action>]]\n"
+ " traceover {<filename>|OFF}[,<cpu>[,<detectloops>[,<action>]]]\n"
"\n"
"Starts or stops tracing of the execution of the specified <cpu>. When tracing reaches "
"a subroutine or call, tracing will skip over the subroutine. The same algorithm is used as is "
"used in the step over command. This means that traceover will not work properly when calls "
"are recusive or the return address is not immediately following the call instruction. If "
- "<cpu> is omitted, the currently active CPU is specified. When enabling tracing, specify the "
- "filename in the <filename> parameter. To disable tracing, substitute the keyword 'off' for "
- "<filename>. If you wish to log additional information on each trace, you can append an <action> "
- "parameter which is a command that is executed before each trace is logged. Generally, this is "
- "used to include a 'tracelog' command. Note that you may need to embed the action within braces "
- "{ } in order to prevent commas and semicolons from being interpreted as applying to the trace "
- "command itself.\n"
+ "<detectloops> should be either true or false. If <detectloops> is true or omitted, the trace "
+ "will have loops detected and condensed to a single line. If it is false, the trace will contain "
+ "every opcode as it is executed. If <cpu> is omitted, the currently active CPU is specified. When "
+ "enabling tracing, specify the filename in the <filename> parameter. To disable tracing, substitute "
+ "the keyword 'off' for <filename>. If you wish to log additional information on each trace, you can "
+ "append an <action> parameter which is a command that is executed before each trace is logged. "
+ "Generally, this is used to include a 'tracelog' command. Note that you may need to embed the "
+ "action within braces { } in order to prevent commas and semicolons from being interpreted as "
+ "applying to the trace command itself.\n"
"\n"
"Examples:\n"
"\n"
+ "traceover joust.tr\n"
+ " Begin tracing the currently active CPU, logging output to joust.tr.\n"
+ "\n"
"traceover dribling.tr,0\n"
" Begin tracing the execution of CPU #0, logging output to dribling.tr.\n"
"\n"
- "traceover joust.tr\n"
- " Begin tracing the currently active CPU, logging output to joust.tr.\n"
+ "traceover starswep.tr,0,false\n"
+ " Begin tracing the execution of CPU #0, logging output to starswep.tr, with loop detection disabled.\n"
"\n"
"traceover off,0\n"
" Turn off tracing on CPU #0.\n"
"\n"
- "traceover asteroid.tr,0,{tracelog \"A=%02X \",a}\n"
+ "traceover asteroid.tr,0,true,{tracelog \"A=%02X \",a}\n"
" Begin tracing the execution of CPU #0, logging output to asteroid.tr. Before each line, "
"output A=<aval> to the tracelog.\n"
},