|
GEOS SDK TechDocs
|
|
assign ...
|
car ...
bits
bits [<address>] [<length>] [<type>]
Examples:
-
"bits"
- lists 16 bytes worth of bits at ds:si
-
"bits ds:di 8"
-
lists 8 bytes worth of bits at ds:di
-
"bits ds:di 24 w"
-
lists 24 words worth of bits at ds:di
Examine memory as a dump of bits in sets of 8, 16, or 32 (byte,word, or dword).
-
The address argument is the address to examine. If not specified, the address after the last examined memory location is used. If no address has been examined then ds:si is used for the address.
-
The length argument is the number of units to examine. It defaults to 16.
-
They type argument is bytes, words or dwords. It defaults to bytes.
-
Pressing return after this command continues the list.
break-taken
break-taken [<flag>]
Examples:
-
"break-taken"
-
Returns 1 if the machine stopped because of a breakpoint.
-
"break-taken 0"
-
Specify that no breakpoint was actually taken to stop the machine.
Obscure. This is used to determine if the machine stopped because a breakpoint was hit and taken.
Setting the
break-taken
flag is a rather obscure operation. It is useful primarily in complex commands that single-step the machine until a particular address is reached, or a breakpoint is taken when a breakpoint must be used to skip over a procedure call, or condense multiple iterations of an instruction with a REP prefix into 1. For an example of this use, refer to the "cycles" command.
See Also: brk,
irq.
brkload
brkload [<handle>]
Examples:
-
"brkload Interface"
-
Stop the machine when the Interface resource is loaded or swapped in.
-
"brkload bx"
- Stop the machine when the resource whose handle ID is in BX is loaded or swapped in.
-
"brkload"
- Stop watching for the previously-specified resource to be loaded.
Stop the machine when a particular resource is loaded into memory.
-
Only one brkload may be active at a time; registering a second one automatically unregisters the first.
-
If you give no <handle> argument, the previously-set brkload will be unregistered.
See Also: handle.
byteAsChar
var byteAsChar [(0|1)]
Examples:
-
"var byteAsChar 1"
-
Print byte variables as characters.
Determines how unsigned character variables are printed: if set non-zero, they are displayed as characters, else they are treated as unsigned integers.
-
If $byteAsChar
is 0, $intFormat is used.
-
The default value for this variable is 0.
bytes
bytes [<address>] [<length>]
Examples:
-
"bytes"
- lists 16 bytes at DS:SI
-
"bytes ds:di 32"
-
lists 32 bytes at DS:SI
Examine memory as a dump of bytes and characters.
-
The <address> argument is the address to examine. If not specified, the address after the last examined memory location is used. If no address has been examined then DS:SI is used for the address.
-
The <length> argument is the number of bytes to examine. It defaults to 16.
-
Pressing <Return> after this command continues the list.
-
Characters which are not typical ASCII values are displayed as a period.
See Also: words,
dwords,
imem,
assign.
call
call <function> [<function args>]
Examples: "call MyFunc"
"call MyDraw ax 1 bx 1 cx 10h dx 10h"
"call FindArea box.bottom 5 box.right 5 push box"'
Call a function in the current thread.
-
The <function> argument is the function to call. If it is a NEAR function, the thread must already be executing in the function's segment.
-
The function arguments are in pairs <variable/register> <value>. These pairs are passed to the "assign" command. As a special case, if the variable is "push", the value (a word) is pushed onto the stack and is popped when the call finishes (if it completes successfully).
-
All current registers are preserved and restored when the call is complete. Variables are not.
-
Once the call has completed, you are left in a sub-interpreter to examine the state of the machine. Type "break" to get back to the top level.
-
If the machine stops for any other reason than the call's completion, the saved register state is discarded and you are left wherever the machine stopped. You will not be able to get a stack trace above the called function, but if the call eventually completes, and no registers have actually been modified, things will get back on track.
-
You may not call a function from a thread that has retreated into the kernel. This function also will not allow you to call
ThreadExit()
. Use the "exit" function to do that.
See Also: assign,
call-patient,
patch.
call-patient
call-patient <function> ((<reg>|push) <value>)*
Examples:
-
"call-patient MemLock bx $h"
-
Locks down the block whose handle ID is in $h.
This is a utility routine, not intended for use from the command line, that will call a routine in the PC after setting registers to or pushing certain values.
-
Returns non-zero if the call completed successfully.
-
If the call is successful, the registers reflect the state of the machine upon return from the called routine. The previous machine state is preserved and can be retrieved, by invoking restore-state, or thrown away, by invoking discard-state. The caller
must
invoke one of these to clean up.
-
Arguments after <function> are as for "call".
-
If the called routine is in movable memory, this will lock the containing block down before issuing the call, as you'd expect.
-
Calling anything that makes message calls while on the geos:0 thread is a hazardous undertaking at best.
See Also: call.
|
GEOS SDK TechDocs
|
|
assign ...
|
car ...