| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
#ifndef cpu_type_H |
| 7 |
#define cpu_type_H |
| 8 |
|
| 9 |
|
| 10 |
#include "config.h" |
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
struct cpu_type { |
| 16 |
|
| 17 |
|
| 18 |
boolean (*keyword_is_mnemonic)(int); |
| 19 |
bits flags; |
| 20 |
|
| 21 |
int dummy_pc; |
| 22 |
unsigned char default_align_value; |
| 23 |
|
| 24 |
|
| 25 |
}; |
| 26 |
#define CPUFLAG_INDIRECTJMPBUGGY (1u << 0) // warn if "jmp ($xxff)" is assembled |
| 27 |
#define CPUFLAG_SUPPORTSLONGREGS (1u << 1) // allow "!al" and "!rl" pseudo opcodes |
| 28 |
#define CPUFLAG_8B_AND_AB_NEED_0_ARG (1u << 2) // warn if "ane/lxa #$xx" uses non-zero arg |
| 29 |
#define CPUFLAG_ISBIGENDIAN (1u << 3) // for 16/24/32-bit values, output msb first |
| 30 |
#define CPUFLAG_DECIMALSUBTRACTBUGGY (1u << 4) // warn if "sed" is assembled |
| 31 |
#define CPUFLAG_WARN_ABOUT_FF_PTR (1u << 5) // warn if MNEMO($ff) is assembled |
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
|
| 36 |
extern const char cputype_names[]; |
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
|
| 41 |
extern const struct cpu_type *cpu_current_type; |
| 42 |
extern boolean cpu_a_is_long; |
| 43 |
extern boolean cpu_xy_are_long; |
| 44 |
|
| 45 |
|
| 46 |
|
| 47 |
|
| 48 |
|
| 49 |
|
| 50 |
extern void vcpu_check_and_set_reg_length(boolean *var, boolean make_long); |
| 51 |
|
| 52 |
|
| 53 |
extern void cputype_passinit(void); |
| 54 |
|
| 55 |
|
| 56 |
extern const struct cpu_type *cputype_find(void); |
| 57 |
|
| 58 |
|
| 59 |
#endif |