From 5f3a128fbff51dd6fe6f7549d777cf3bdef62982 Mon Sep 17 00:00:00 2001 From: Michael Buesch Date: Thu, 5 Jun 2008 17:50:14 +0200 Subject: [PATCH] b43-asm: Allow complex immediates in M and S operands. Signed-off-by: Michael Buesch --- assembler/parser.y | 2 +- assembler/test.asm | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/assembler/parser.y b/assembler/parser.y index 84a5c24..f015121 100644 --- a/assembler/parser.y +++ b/assembler/parser.y @@ -987,7 +987,7 @@ raw_code : RAW_CODE { } ; -extended_operlist : decnum COMMA decnum COMMA operand COMMA operand COMMA operand { +extended_operlist : imm_value COMMA imm_value COMMA operand COMMA operand COMMA operand { struct operlist *ol = xmalloc(sizeof(struct operlist)); struct operand *mask_oper = xmalloc(sizeof(struct operand)); struct operand *shift_oper = xmalloc(sizeof(struct operand)); diff --git a/assembler/test.asm b/assembler/test.asm index b0e86d9..54dafed 100644 --- a/assembler/test.asm +++ b/assembler/test.asm @@ -169,6 +169,7 @@ function_b: mov testlabel, r0 /* Can use label as immediate value */ mov r0,r1;mov r2, r3 /* ; does split instructions */ mov [(1+1)],[(2+2),off0] /* Can use complex immediates as memory offsets */ + orx (0 + 1), (1 * 2), 0, 0, r0 /* Allow complex immediates as M or S */ /* The .initvals section generates an "Initial Values" file -- 2.31.1