Breakpoint

struct Breakpoint

Represents a Break Rule data.  It is used in the debugger.

See Also

<BreakpointEvaluator> DebuggerInterface

Summary
BreakpointRepresents a Break Rule data.
Functions
EvaluateEvaluates break condition.
ParseParses a condition string.
ToStringMakes the Break Rule readable by putting it into a string.
BreakpointsEvaluatorHolds and evaluates break conditions
Variables
breakpointsThe list of breakpoints (break rules) currently active.
breakpointHitIDIf some rule causes a break, its ID will be stored here.
memoryA pointer to the memory of the GBA.
cpuA pointer to the cpu of the GBA.
Functions
EvaluateEvaluates all the breakrules.
DebuggerInterfaceThis class handles ncurses to draw and update the logic of the debugger terminal interface
Functions
DebuggerInterfaceInitializes the interface.
SetRedrawAllSets the right flags to make a full refresh happen at the next Draw call.
InitializeInitializes ncurses and the windows fields in the interface.
ResizeResizes windows to fill the available area.
UpdateUpdates the logic of the debugger.
DrawDraws all the windows in the terminal.

Functions

Evaluate

bool Evaluate(Memory *mem,
CPU *cpu,
int address)

Evaluates break condition.

Parameters

memThe memory used for evaluation.
cpuThe cpu used for evaluation
addressThe current address.

Returns

True if the conditions are met, false otherwise.

Parse

bool Parse(char *str)

Parses a condition string.

Parameters

strThe string to parse.

Returns

True if the string belongs to the language generated by the grammar of BreakPoint Rules Condition.  False otherwise.

ToString

void ToString(char *str)

Makes the Break Rule readable by putting it into a string.

Parameters

strThe buffer that will contain the converted string.

BreakpointsEvaluator

struct BreakpointsEvaluator

Holds and evaluates break conditions

See Also

Breakpoint DebuggerInterface

Summary
Variables
breakpointsThe list of breakpoints (break rules) currently active.
breakpointHitIDIf some rule causes a break, its ID will be stored here.
memoryA pointer to the memory of the GBA.
cpuA pointer to the cpu of the GBA.
Functions
EvaluateEvaluates all the breakrules.

Variables

breakpoints

std::vector<Breakpoint> breakpoints

The list of breakpoints (break rules) currently active.

breakpointHitID

int breakpointHitID

If some rule causes a break, its ID will be stored here.

memory

Memory* memory

A pointer to the memory of the GBA.

cpu

CPU* cpu

A pointer to the cpu of the GBA.

Functions

Evaluate

bool Evaluate(int address)

Evaluates all the breakrules.

Parameters

addressThe current address

Returns

True if a break shall be generated.

DebuggerInterface

class DebuggerInterface

This class handles ncurses to draw and update the logic of the debugger terminal interface

See Also

GBA CPU Memory BreakpointsEvaluator Breakpoint

Summary
Functions
DebuggerInterfaceInitializes the interface.
SetRedrawAllSets the right flags to make a full refresh happen at the next Draw call.
InitializeInitializes ncurses and the windows fields in the interface.
ResizeResizes windows to fill the available area.
UpdateUpdates the logic of the debugger.
DrawDraws all the windows in the terminal.

Functions

DebuggerInterface

DebuggerInterface(Memory *_mem,  
CPU *_cpu,  
bool startTrace = false)

Initializes the interface.

Parameters

_memThe memory of the GBA.
_cpuThe cpu of the GBA.
startTraceIf true, the debugger will start in Trace-Mode.

SetRedrawAll

void SetRedrawAll()

Sets the right flags to make a full refresh happen at the next Draw call.

See Also

Draw

Initialize

void Initialize()

Initializes ncurses and the windows fields in the interface.

Resize

void Resize()

Resizes windows to fill the available area.

Update

bool Update(int cycles)

Updates the logic of the debugger.

Parameters

cyclesHow many cycles have passed since the last time.

Returns

If true, allows the GBA to continue its execution.

Draw

void Draw()

Draws all the windows in the terminal.

struct Breakpoint
Represents a Break Rule data.
bool Evaluate(Memory *mem,
CPU *cpu,
int address)
Evaluates break condition.
bool Parse(char *str)
Parses a condition string.
void ToString(char *str)
Makes the Break Rule readable by putting it into a string.
struct BreakpointsEvaluator
Holds and evaluates break conditions
std::vector<Breakpoint> breakpoints
The list of breakpoints (break rules) currently active.
int breakpointHitID
If some rule causes a break, its ID will be stored here.
Memory* memory
A pointer to the memory of the GBA.
CPU* cpu
A pointer to the cpu of the GBA.
bool Evaluate(int address)
Evaluates all the breakrules.
class DebuggerInterface
This class handles ncurses to draw and update the logic of the debugger terminal interface
DebuggerInterface(Memory *_mem,  
CPU *_cpu,  
bool startTrace = false)
Initializes the interface.
void SetRedrawAll()
Sets the right flags to make a full refresh happen at the next Draw call.
void Draw()
Draws all the windows in the terminal.
void Initialize()
Initializes ncurses and the windows fields in the interface.
void Resize()
Resizes windows to fill the available area.
bool Update(int cycles)
Updates the logic of the debugger.
class GBA
This is the class representing the entire device.
class CPU
This class represents an ARM7TDMI CPU running at 16.78MHZ with 32 bit registers and two execution modes (ARM32bit, THUMB16bit).
struct Memory
Represents the entire address space of the GBA.
Close