|
GEOS SDK TechDocs
|
|
continue-patient ...
|
debug ...
dbrk
dbrk <addr> <num> [<command>|default]
dbrk set <break> <num> [<command>|default]
dbrk list [<break>]
dbrk {clear,delete} <break>
dbrk cur <break> <num>
dbrk max <break> <num>
dbrk cmd <break> [<command>]
dbrk reset <break>
dbrk enable <break>
dbrk disable <break>
Examples:
-
"dbrk ObjMessage 30"
-
Break at the 30th call to ObjMessage
-
"dbrk set 5 30"
-
Break after hitting brk5 30 times.
-
"dbrk set brk3 10 default"
-
Break after hitting brk3 10 times; Each time brk3 is hit, perform the default command.
-
"dbrk cmd brk2 {echo foo}"
-
Echo a string whenever brk2 is hit.
-
"dbrk cmd brk2 default"
-
Use the default command for brk2.
-
"dbrk disable 2"
-
Stop counting brk2; it will now always be taken.
This command creates "delayed" breakpoints, creating breakpoints that don't activate until they've been hit a specified nuber of times.
-
break
may be a number, or a full breakpoint token (brk<n>)
num
is a number; and
command
is a string that will be evaluated. If
command
may also be the string "default", in which case a default command will be used. The first argument to dbrk may be abbreviated; only the first 3 characters are significant.
-
Deleting a breakpoint with "brk del" removes the dbrk also.
-
With the exception of brk, all the commands that take <break> must be given a breakpoint that has been delayed. The "dbrk list" command will show these.
-
"dbrk list" will show how many times a breakpoint has been hit, the maximum number of times to skip the breakpoint, and the command to evaluate whenever the breakpoint is hit. If no breakpoint is passed, the status of all dbrks will be shown.
-
"dbrk clear" and "dbrk delete" are synonyms. These commands will cause the delayed breakpoint to become normal again, and clear out the global variables used to store the dbrk's state: brk
N
cur, brk
N
max, brk
N
cmd where
N
is a number.
-
"dbrk cur", "dbrk max", and "dbrk cmd" set the current count, the maximum count, and the command of the specified breakpoint respectively.
-
"dbrk reset
break
" is a quick way of saying "dbrk cur
break
0"
-
"dbrk enable" and "dbrk disable" are used to enable and disable a dbrk. Disabled dbrks will always be taken, and their counter will not be incremented.
-
Since this command is just a front-end to brk cmd, you can use dbrk and brk cond to create more complex breakpoints; for instance, you can "mwatch
MSG_VIS_DRAW
", then "dbrk set
brk
30 print-method" to break after
MSG_VIS_DRAW
has been received 30 times.
dcache
dcache bsize <blockSize>
dcache length <numBlocks>
dcache stats
dcache params
dcache (on|off)
Examples:
-
"dcache bsize 16"
-
Set the number of bytes fetched at a time to 16.
-
"dcache length 1024"
-
Allow 1024 blocks of the current block size to be in the cache at a time.
-
"dcache off"
- Disables the Swat data cache.
Controls the cache Swat uses to hold data read from the target machine while the machine is stopped.
-
Data written while the machine is stopped actually get written to the cache, not the PC, and the modified blocks are written when the machine is continued.
-
The default cache block size is 32 bytes, with a default cache length of 64 blocks.
-
It is a very rare thing to have to turn the data cache off. You might need to do this while examining the changing registers of a memory-mapped I/O device.
-
The <blockSize> must be a power of 2 and no more than 128.
-
Changing the block size causes all cached blocks to be flushed (any modified cache blocks are written to the PC).
-
Changing the cache length will only flush blocks if there are more blocks currently in the cache than are allowed by the new length.
-
The "dcache stats" command prints statistics giving some indication of the efficacy of the data cache. It does not return anything.
-
The "dcache params" command returns a list {<blockSize> <numBlocks>} giving the current parameters of the data cache. There are some operations where you might want to adjust the size of the cache either up or down, but need to reset the parameters when the operation completes. This is what you need to do this.
See Also: cache.
dcall
dcall [<args>]
Examples:
-
"dcall Dispatch"
-
Display when the routine Dispatch is called
-
"dcall none"
-
stop displaying all routines
Display calls to a routine.
-
The <args> argument normally is the name of the routine to monitor. Whenever a call is made to the routine its name is displayed.
-
If `none' or no argument is passed, then all the routines will stop displaying.
-
Dcall uses breakpoints to display routine names. By looking at the list of breakpoints you can see which routines display their names and you can stop them individually by disabling or deleting their breakpoints.
See Also: showcalls,
mwatch.
|
GEOS SDK TechDocs
|
|
continue-patient ...
|
debug ...