arch-riscv: Fix disassembling of operand list for compressed instructions
authorIan Jiang <ianjiang.ict@gmail.com>
Thu, 31 Oct 2019 06:27:35 +0000 (14:27 +0800)
committerIan Jiang <ianjiang.ict@gmail.com>
Mon, 25 Nov 2019 01:26:08 +0000 (01:26 +0000)
commitbee784dee932f66cefc702971a01a35f3436e929
treeb1026306f7e7d1201a04eadca7f2d58f3edf813c
parent27b5e32e94cf79c065a49d184b5a0dcad83399c3
arch-riscv: Fix disassembling of operand list for compressed instructions

In disassembling compressed instructions, the original Gem5 gives needless
operands, such as register or immediate. This patch fixes the problem.
- Existing formats fixed: CIOp, CJOp, CBOp and Jump.
- New formats added: CIAddi4spnOp (for c.addi4spn only) and CompressedROp (with
  templates CBasicDeclare and CBasicExecute)

Change-Id: Ic293836983256a59d3a7aca091c8184b410516a4
Signed-off-by: Ian Jiang <ianjiang.ict@gmail.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/22566
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
Reviewed-by: Alec Roelke <alec.roelke@gmail.com>
Maintainer: Alec Roelke <alec.roelke@gmail.com>
src/arch/riscv/isa/decoder.isa
src/arch/riscv/isa/formats/compressed.isa
src/arch/riscv/isa/formats/standard.isa