;
/* ASM directives */
-asmdir : asmarch {
- $$ = $1;
+asmdir : ASM_ARCH hexnum_decnum {
+ struct asmdir *ad = xmalloc(sizeof(struct asmdir));
+ ad->type = ADIR_ARCH;
+ ad->u.arch = (unsigned int)(unsigned long)$2;
+ $$ = ad;
}
| ASM_START identifier {
struct asmdir *ad = xmalloc(sizeof(struct asmdir));
}
;
-asmarch : ASM_ARCH ARCH_NEWWORLD {
- struct asmdir *ad = xmalloc(sizeof(struct asmdir));
- ad->type = ADIR_ARCH;
- ad->u.arch = NEWWORLD;
- $$ = ad;
- }
- | ASM_ARCH ARCH_OLDWORLD {
- struct asmdir *ad = xmalloc(sizeof(struct asmdir));
- ad->type = ADIR_ARCH;
- ad->u.arch = OLDWORLD;
- $$ = ad;
- }
- ;
-
label : LABEL {
struct label *label = xmalloc(sizeof(struct label));
char *l;
}
;
-external_jump_operands : hexnum COMMA operand COMMA operand COMMA labelref {
+external_jump_operands : imm COMMA operand COMMA operand COMMA labelref {
struct operlist *ol = xmalloc(sizeof(struct operlist));
struct operand *cond = xmalloc(sizeof(struct operand));
- cond->type = OPER_RAW;
- cond->u.raw = (unsigned long)$1;
+ cond->type = OPER_IMM;
+ cond->u.imm = $1;
ol->oper[0] = cond;
ol->oper[1] = $3;
ol->oper[2] = $5;