Mercurial > hg-old > index.cgi
comparison lwasm/instab.h @ 360:7d91ab7ac7d6
Indexed stage 2; set line structure to track pragmas in effect for that line
author | lost@starbug |
---|---|
date | Thu, 01 Apr 2010 18:39:40 -0600 |
parents | 11a95c6414b4 |
children | fbb7bfed8076 |
comparison
equal
deleted
inserted
replaced
359:f50a54d0293a | 360:7d91ab7ac7d6 |
---|---|
29 typedef struct | 29 typedef struct |
30 { | 30 { |
31 char *opcode; /* the mneumonic */ | 31 char *opcode; /* the mneumonic */ |
32 int ops[4]; /* opcode values for up to four addr modes */ | 32 int ops[4]; /* opcode values for up to four addr modes */ |
33 void (*parse)(asmstate_t *as, line_t *l, char **optr); /* parse operand for insn */ | 33 void (*parse)(asmstate_t *as, line_t *l, char **optr); /* parse operand for insn */ |
34 void (*resolve)(asmstate_t *as, line_t *l); /* resolve instruction to code */ | 34 void (*resolve)(asmstate_t *as, line_t *l, int force); /* resolve instruction to code */ |
35 void (*emit)(asmstate_t *as, line_t *l); /* resolve instruction to code */ | 35 void (*emit)(asmstate_t *as, line_t *l); /* resolve instruction to code */ |
36 int flags; /* flag for this instruction */ | 36 int flags; /* flag for this instruction */ |
37 } instab_t; | 37 } instab_t; |
38 | 38 |
39 enum | 39 enum |
45 lwasm_insn_is6309 = 8 /* insn is 6309 only */ | 45 lwasm_insn_is6309 = 8 /* insn is 6309 only */ |
46 }; | 46 }; |
47 | 47 |
48 | 48 |
49 #define PARSEFUNC(fn) void (fn)(asmstate_t *as, line_t *l, char **p) | 49 #define PARSEFUNC(fn) void (fn)(asmstate_t *as, line_t *l, char **p) |
50 #define RESOLVEFUNC(fn) void (fn)(asmstate_t *as, line_t *l) | 50 #define RESOLVEFUNC(fn) void (fn)(asmstate_t *as, line_t *l, int force) |
51 #define EMITFUNC(fn) void (fn)(asmstate_t *as, line_t *l) | 51 #define EMITFUNC(fn) void (fn)(asmstate_t *as, line_t *l) |
52 | 52 |
53 #ifndef __instab_c_seen__ | 53 #ifndef __instab_c_seen__ |
54 extern instab_t instab[]; | 54 extern instab_t instab[]; |
55 #endif //__instab_c_seen__ | 55 #endif //__instab_c_seen__ |