Search
lxdream.org :: lxdream/src/mem.h :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/mem.h
changeset 586:2a3ba82cf243
prev543:361ec0a70cf2
next669:ab344e42bca9
author nkeynes
date Tue Jan 15 20:50:23 2008 +0000 (14 years ago)
permissions -rw-r--r--
last change Merged lxdream-mmu r570:596 to trunk
file annotate diff log raw
1.1 --- a/src/mem.h Thu Nov 22 11:10:15 2007 +0000
1.2 +++ b/src/mem.h Tue Jan 15 20:50:23 2008 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: mem.h,v 1.17 2007-11-14 10:21:33 nkeynes Exp $
1.6 + * $Id$
1.7 *
1.8 * mem is responsible for creating and maintaining the overall system memory
1.9 * map, as visible from the SH4 processor. (Note the ARM has a different map)
1.10 @@ -63,7 +63,7 @@
1.11 sh4ptr_t mem_get_page( uint32_t addr );
1.12 int mem_load_block( const gchar *filename, uint32_t base, uint32_t size );
1.13 int mem_save_block( const gchar *filename, uint32_t base, uint32_t size );
1.14 -void mem_set_trace( uint32_t addr, int flag );
1.15 +void mem_set_trace( const gchar *tracelist, int flag );
1.16 void mem_init( void );
1.17 void mem_reset( void );
1.18 void mem_copy_from_sh4( sh4ptr_t dest, sh4addr_t src, size_t count );
1.19 @@ -71,25 +71,23 @@
1.20
1.21 #define ENABLE_DEBUG_MODE 1
1.22
1.23 +typedef enum { BREAK_NONE=0, BREAK_ONESHOT=1, BREAK_KEEP=2 } breakpoint_type_t;
1.24 +
1.25 struct breakpoint_struct {
1.26 uint32_t address;
1.27 - int type;
1.28 + breakpoint_type_t type;
1.29 };
1.30
1.31 #define MAX_BREAKPOINTS 32
1.32 -#define BREAK_NONE 0
1.33 -#define BREAK_ONESHOT 1
1.34 -#define BREAK_KEEP 2
1.35
1.36 -#undef ENABLE_WATCH
1.37 +
1.38 +#define MEM_FLAG_ROM 4 /* Mem region is ROM-based */
1.39 +#define MEM_FLAG_RAM 6
1.40
1.41 #define WATCH_WRITE 1
1.42 #define WATCH_READ 2
1.43 #define WATCH_EXEC 3 /* AKA Breakpoint :) */
1.44
1.45 -#define MEM_FLAG_ROM 4 /* Mem region is ROM-based */
1.46 -#define MEM_FLAG_RAM 6
1.47 -
1.48 typedef struct watch_point *watch_point_t;
1.49
1.50 watch_point_t mem_new_watch( uint32_t start, uint32_t end, int flags );
.