Mercurial > repos > blastem
comparison m68k_internal.h @ 1082:2ec5e6eaf81d
Add support for specifying a reset handler in the M68K core. Adjust memory map initialization to handle extra field. Improved handling of out of bounds execution.
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Thu, 06 Oct 2016 09:34:31 -0700 |
parents | 33a46d35b913 |
children | c15896605bf2 |
comparison
equal
deleted
inserted
replaced
1081:89cc20cf1ad3 | 1082:2ec5e6eaf81d |
---|---|
7 #define M68K_INTERNAL_H_ | 7 #define M68K_INTERNAL_H_ |
8 | 8 |
9 #include "68kinst.h" | 9 #include "68kinst.h" |
10 | 10 |
11 //functions implemented in host CPU specfic file | 11 //functions implemented in host CPU specfic file |
12 void translate_out_of_bounds(code_info *code); | 12 void translate_out_of_bounds(m68k_options *opts, uint32_t address); |
13 void areg_to_native(m68k_options *opts, uint8_t reg, uint8_t native_reg); | 13 void areg_to_native(m68k_options *opts, uint8_t reg, uint8_t native_reg); |
14 void dreg_to_native(m68k_options *opts, uint8_t reg, uint8_t native_reg); | 14 void dreg_to_native(m68k_options *opts, uint8_t reg, uint8_t native_reg); |
15 void areg_to_native_sx(m68k_options *opts, uint8_t reg, uint8_t native_reg); | 15 void areg_to_native_sx(m68k_options *opts, uint8_t reg, uint8_t native_reg); |
16 void dreg_to_native_sx(m68k_options *opts, uint8_t reg, uint8_t native_reg); | 16 void dreg_to_native_sx(m68k_options *opts, uint8_t reg, uint8_t native_reg); |
17 void native_to_areg(m68k_options *opts, uint8_t native_reg, uint8_t reg); | 17 void native_to_areg(m68k_options *opts, uint8_t native_reg, uint8_t reg); |
40 int8_t native_reg(m68k_op_info * op, m68k_options * opts); | 40 int8_t native_reg(m68k_op_info * op, m68k_options * opts); |
41 size_t dreg_offset(uint8_t reg); | 41 size_t dreg_offset(uint8_t reg); |
42 size_t areg_offset(uint8_t reg); | 42 size_t areg_offset(uint8_t reg); |
43 size_t reg_offset(m68k_op_info *op); | 43 size_t reg_offset(m68k_op_info *op); |
44 void translate_m68k_op(m68kinst * inst, host_ea * ea, m68k_options * opts, uint8_t dst); | 44 void translate_m68k_op(m68kinst * inst, host_ea * ea, m68k_options * opts, uint8_t dst); |
45 void print_regs_exit(m68k_context * context); | |
46 void m68k_read_size(m68k_options *opts, uint8_t size); | 45 void m68k_read_size(m68k_options *opts, uint8_t size); |
47 void m68k_write_size(m68k_options *opts, uint8_t size, uint8_t lowfirst); | 46 void m68k_write_size(m68k_options *opts, uint8_t size, uint8_t lowfirst); |
48 void m68k_save_result(m68kinst * inst, m68k_options * opts); | 47 void m68k_save_result(m68kinst * inst, m68k_options * opts); |
49 void push_const(m68k_options *opts, int32_t value); | 48 void push_const(m68k_options *opts, int32_t value); |
50 void jump_m68k_abs(m68k_options * opts, uint32_t address); | 49 void jump_m68k_abs(m68k_options * opts, uint32_t address); |
86 void translate_m68k_andi_ori_ccr_sr(m68k_options *opts, m68kinst *inst); | 85 void translate_m68k_andi_ori_ccr_sr(m68k_options *opts, m68kinst *inst); |
87 void translate_m68k_eori_ccr_sr(m68k_options *opts, m68kinst *inst); | 86 void translate_m68k_eori_ccr_sr(m68k_options *opts, m68kinst *inst); |
88 void translate_m68k_move_ccr_sr(m68k_options *opts, m68kinst *inst, host_ea *src_op, host_ea *dst_op); | 87 void translate_m68k_move_ccr_sr(m68k_options *opts, m68kinst *inst, host_ea *src_op, host_ea *dst_op); |
89 void translate_m68k_stop(m68k_options *opts, m68kinst *inst); | 88 void translate_m68k_stop(m68k_options *opts, m68kinst *inst); |
90 void translate_m68k_move_from_sr(m68k_options *opts, m68kinst *inst, host_ea *src_op, host_ea *dst_op); | 89 void translate_m68k_move_from_sr(m68k_options *opts, m68kinst *inst, host_ea *src_op, host_ea *dst_op); |
90 void translate_m68k_reset(m68k_options *opts, m68kinst *inst); | |
91 | 91 |
92 //flag update bits | 92 //flag update bits |
93 #define X0 0x0001 | 93 #define X0 0x0001 |
94 #define X1 0x0002 | 94 #define X1 0x0002 |
95 #define X 0x0004 | 95 #define X 0x0004 |