This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] RISC-V: Mark "c.nop" as an alias


Committed.

On Mon, 21 Aug 2017 17:33:04 PDT (-0700), Palmer Dabbelt wrote:
> This fixes "-M noaliases" disassembly for "c.nop", which is an alias for
> "c.addi x0, 0".
>
> opcodes/ChangeLog
>
> 2017-08-01  Palmer Dabbelt  <palmer@dabbelt.com>
>
>         * riscv-opc.c (riscv_opcodes): Mark "c.nop" as an alias.
> ---
>  opcodes/riscv-opc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/opcodes/riscv-opc.c b/opcodes/riscv-opc.c
> index 9914c4474429..70a362859ccc 100644
> --- a/opcodes/riscv-opc.c
> +++ b/opcodes/riscv-opc.c
> @@ -619,7 +619,7 @@ const struct riscv_opcode riscv_opcodes[] =
>  {"c.lw",      "C",   "Ct,Ck(Cs)",  MATCH_C_LW, MASK_C_LW, match_opcode, 0 },
>  {"c.swsp",    "C",   "CV,CM(Cc)",  MATCH_C_SWSP, MASK_C_SWSP, match_opcode, 0 },
>  {"c.sw",      "C",   "Ct,Ck(Cs)",  MATCH_C_SW, MASK_C_SW, match_opcode, 0 },
> -{"c.nop",     "C",   "",  MATCH_C_ADDI, 0xffff, match_opcode, 0 },
> +{"c.nop",     "C",   "",  MATCH_C_ADDI, 0xffff, match_opcode, INSN_ALIAS },
>  {"c.mv",      "C",   "d,CV",  MATCH_C_MV, MASK_C_MV, match_c_add, 0 },
>  {"c.lui",     "C",   "d,Cu",  MATCH_C_LUI, MASK_C_LUI, match_c_lui, 0 },
>  {"c.li",      "C",   "d,Co",  MATCH_C_LI, MASK_C_LI, match_rd_nonzero, 0 },


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]