| 109 |
#if TARGET_LONG_SIZE == 4 |
#if TARGET_LONG_SIZE == 4 |
| 110 |
#define tswapl(s) tswap32(s) |
#define tswapl(s) tswap32(s) |
| 111 |
#define tswapls(s) tswap32s((uint32_t *)(s)) |
#define tswapls(s) tswap32s((uint32_t *)(s)) |
| 112 |
|
#define bswaptls(s) bswap32s(s) |
| 113 |
#else |
#else |
| 114 |
#define tswapl(s) tswap64(s) |
#define tswapl(s) tswap64(s) |
| 115 |
#define tswapls(s) tswap64s((uint64_t *)(s)) |
#define tswapls(s) tswap64s((uint64_t *)(s)) |
| 116 |
|
#define bswaptls(s) bswap64s(s) |
| 117 |
#endif |
#endif |
| 118 |
|
|
| 119 |
/* NOTE: arm FPA is horrible as double 32 bit words are stored in big |
/* NOTE: arm FPA is horrible as double 32 bit words are stored in big |
| 735 |
int cpu_memory_rw_debug(CPUState *env, target_ulong addr, |
int cpu_memory_rw_debug(CPUState *env, target_ulong addr, |
| 736 |
uint8_t *buf, int len, int is_write); |
uint8_t *buf, int len, int is_write); |
| 737 |
|
|
| 738 |
|
#define VGA_DIRTY_FLAG 0x01 |
| 739 |
|
|
| 740 |
/* read dirty bit (return 0 or 1) */ |
/* read dirty bit (return 0 or 1) */ |
| 741 |
static inline int cpu_physical_memory_is_dirty(target_ulong addr) |
static inline int cpu_physical_memory_is_dirty(target_ulong addr) |
| 742 |
{ |
{ |
| 743 |
return phys_ram_dirty[addr >> TARGET_PAGE_BITS]; |
return phys_ram_dirty[addr >> TARGET_PAGE_BITS] == 0xff; |
| 744 |
|
} |
| 745 |
|
|
| 746 |
|
static inline int cpu_physical_memory_get_dirty(target_ulong addr, |
| 747 |
|
int dirty_flags) |
| 748 |
|
{ |
| 749 |
|
return phys_ram_dirty[addr >> TARGET_PAGE_BITS] & dirty_flags; |
| 750 |
} |
} |
| 751 |
|
|
| 752 |
static inline void cpu_physical_memory_set_dirty(target_ulong addr) |
static inline void cpu_physical_memory_set_dirty(target_ulong addr) |
| 753 |
{ |
{ |
| 754 |
phys_ram_dirty[addr >> TARGET_PAGE_BITS] = 1; |
phys_ram_dirty[addr >> TARGET_PAGE_BITS] = 0xff; |
| 755 |
} |
} |
| 756 |
|
|
| 757 |
void cpu_physical_memory_reset_dirty(target_ulong start, target_ulong end); |
void cpu_physical_memory_reset_dirty(target_ulong start, target_ulong end, |
| 758 |
|
int dirty_flags); |
| 759 |
|
|
| 760 |
void dump_exec_info(FILE *f, |
void dump_exec_info(FILE *f, |
| 761 |
int (*cpu_fprintf)(FILE *f, const char *fmt, ...)); |
int (*cpu_fprintf)(FILE *f, const char *fmt, ...)); |