DGen/SDL
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Classes | Macros | Functions | Variables
debug.h File Reference
#include <stdint.h>

Go to the source code of this file.

Classes

struct  dgen_bp
 Breakpoint structure. More...
struct  dgen_wp
 Watchpoint structure. More...

Macros

#define MAX_BREAKPOINTS   64
 Maximum number of beakpoints supported.
#define MAX_WATCHPOINTS   64
 Maximum number of watchpoints supported.
#define MAX_DEBUG_TOKS   8
 Maximum number of tokens on the debugger command line.
#define DEBUG_DFLT_DASM_LEN   16
 Default number of instructions to disassemble.
#define DEBUG_DFLT_MEMDUMP_LEN   128
 Default number of bytes to display while dumping memory.
#define DBG_CONTEXT_M68K   0
#define DBG_CONTEXT_Z80   1
#define DBG_CONTEXT_YM2612   2
#define DBG_CONTEXT_SN76489   3
#define BP_FLAG_USED   (1<<0)
 Breakpoint enabled.
#define WP_FLAG_USED   (1<<0)
 Watchpoint enabled.
#define WP_FLAG_FIRED   (1<<1)
 Set when watchpoint fires.

Functions

void debug_init (void)
 Initialise the debugger.
int debug_musa_callback (void)
 Breakpoint/watchpoint handler for Musashi, fired before every M68K instruction.
void debug_show_ym2612_regs (void)

Variables

int m68k_bp_hit
int m68k_wp_hit

Macro Definition Documentation

#define BP_FLAG_USED   (1<<0)

Breakpoint enabled.

#define DBG_CONTEXT_M68K   0
#define DBG_CONTEXT_SN76489   3
#define DBG_CONTEXT_YM2612   2
#define DBG_CONTEXT_Z80   1
#define DEBUG_DFLT_DASM_LEN   16

Default number of instructions to disassemble.

#define DEBUG_DFLT_MEMDUMP_LEN   128

Default number of bytes to display while dumping memory.

#define MAX_BREAKPOINTS   64

Maximum number of beakpoints supported.

#define MAX_DEBUG_TOKS   8

Maximum number of tokens on the debugger command line.

#define MAX_WATCHPOINTS   64

Maximum number of watchpoints supported.

#define WP_FLAG_FIRED   (1<<1)

Set when watchpoint fires.

#define WP_FLAG_USED   (1<<0)

Watchpoint enabled.


Function Documentation

void debug_init ( void  )

Initialise the debugger.

All breakpoints are disabled by default.

int debug_musa_callback ( void  )

Breakpoint/watchpoint handler for Musashi, fired before every M68K instruction.

Returns:
1 if a break/watchpoint is hit, 0 otherwise.
void debug_show_ym2612_regs ( void  )

Variable Documentation

int m68k_bp_hit
int m68k_wp_hit