Appearance
CPUDebuggerAPI
cpp
#include <VAmiga.h>cpp
class CPUDebuggerAPIDefined in VAmiga.h:754
API of the CPU debugger (disassembler and dumps).
Public Methods
| Return | Name | Description |
|---|---|---|
isize | loggedInstructions const | Returns the number of instructions in the record buffer. |
void | clearLog | Empties the record buffer. |
string | disassemble const | Disassembles an instruction. |
string | disassembleRecorded const | Disassembles an instruction from the log buffer. |
string | vectorName const | Returns the name of an exception vector. |
loggedInstructions
const
cpp
isize loggedInstructions() constDefined in VAmiga.h:768
Returns the number of instructions in the record buffer.
NOTE
The record buffer is only filled in track mode. To save computation time, the GUI enables track mode when the CPU inspector is opened and disables track mode when it is closed.
clearLog
cpp
void clearLog()Defined in VAmiga.h:772
Empties the record buffer.
disassemble
const
cpp
string disassemble(u32 addr, const string & fmt, isize * len = nullptr) constDefined in VAmiga.h:787
Disassembles an instruction.
Returns
The disassembled text.
Parameters
| Parameter | Type | Description |
|---|---|---|
addr | u32 | Address of the instruction to disassemble |
fmt | const string & | String defining the output format. The directives are p (address), b (instruction words), i (instruction), f (status register flags), Nd (data register DN) and Na (address register AN, N = 0 ... 7). A number in front of p, b, i, or f pads the output with spaces to the given width. The register directives show the current register contents. |
len | isize * | If given, receives the length of the instruction in bytes. |
Exceptions
| Exception | Description |
|---|---|
CoreError | (CoreError::OPT_INV_ARG) if the format string is invalid. |
disassembleRecorded
const
cpp
string disassembleRecorded(isize nr, const string & fmt, isize * len = nullptr) constDefined in VAmiga.h:798
Disassembles an instruction from the log buffer.
Returns
The disassembled text.
Parameters
| Parameter | Type | Description |
|---|---|---|
nr | isize | Index of the instruction in the record buffer |
fmt | const string & | String defining the output format (see disassemble()). The register directives show the register contents at the time the instruction was recorded. |
len | isize * | If given, receives the length of the instruction in bytes. |
Exceptions
| Exception | Description |
|---|---|
CoreError | (CoreError::OPT_INV_ARG) if the format string is invalid. |
vectorName
const
cpp
string vectorName(isize i) constDefined in VAmiga.h:805
Returns the name of an exception vector.
Returns
A readable name (e.g., "Bus error"), or "Reserved" or a generic name for vectors without a fixed meaning.
Parameters
| Parameter | Type | Description |
|---|---|---|
i | isize | Vector number (0 ... 255) |