diff options
author | Jim Wilson <jimw@sifive.com> | 2019-07-05 15:19:11 +0800 |
---|---|---|
committer | Jim Wilson <jimw@sifive.com> | 2019-07-05 15:19:11 +0800 |
commit | 98602811d838077269e361e9d807fe530c780011 (patch) | |
tree | adddb9536e0ae27b31da8d1ae46e64fab62cda67 /gas/doc | |
parent | a0b6cbf69db7427cfdf054092062fcf82eef9a58 (diff) | |
download | gdb-98602811d838077269e361e9d807fe530c780011.zip gdb-98602811d838077269e361e9d807fe530c780011.tar.gz gdb-98602811d838077269e361e9d807fe530c780011.tar.bz2 |
Kito's 5-part patch set to improve .insn support.
From Kito Cheng <kito.cheng@sifive.com>
gas/ChangeLog
* doc/c-riscv.texi (Instruction Formats): Add r4 type.
* testsuite/gas/riscv/insn.d: Add testcase for r4 type.
* testsuite/gas/riscv/insn.s: Ditto.
* doc/c-riscv.texi (Instruction Formats): Add b and j type.
* testsuite/gas/riscv/insn.d: Add test case for b and j type.
* testsuite/gas/riscv/insn.s: Ditto.
* testsuite/gas/riscv/insn.s: Correct instruction type for load
and store.
* testsuite/gas/riscv/insn.d: Using regular expression to match
address.
* doc/c-riscv.texi (Instruction Formats): Fix encoding table for SB
type and fix typo.
opcode/ChangeLog
* riscv-opc.c (riscv_insn_types): Add r4 type.
* riscv-opc.c (riscv_insn_types): Add b and j type.
* opcodes/riscv-opc.c (riscv_insn_types): Remove incorrect
format for sb type and correct s type.
Diffstat (limited to 'gas/doc')
-rw-r--r-- | gas/doc/c-riscv.texi | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/gas/doc/c-riscv.texi b/gas/doc/c-riscv.texi index 42d1ce3..9bc8c82 100644 --- a/gas/doc/c-riscv.texi +++ b/gas/doc/c-riscv.texi @@ -286,7 +286,7 @@ Opcode space for msub instruction. @item AMO Opcode space for atomic memory operation instructions. -@item MISC_IMM +@item MISC_MEM Opcode space for misc instructions. @item SYSTEM @@ -318,6 +318,7 @@ with the @samp{.insn} pseudo directive: @end verbatim @item R type with 4 register operands: .insn r opcode, func3, func2, rd, rs1, rs2, rs3 +@itemx R4 type: .insn r4 opcode, func3, func2, rd, rs1, rs2, rs3 @verbatim +-----+-------+-----+-----+-------+----+-------------+ | rs3 | func2 | rs2 | rs1 | func3 | rd | opcode | @@ -343,11 +344,13 @@ with the @samp{.insn} pseudo directive: @item SB type: .insn sb opcode, func3, rd, rs1, symbol @itemx SB type: .insn sb opcode, func3, rd, simm12(rs1) +@itemx B type: .insn s opcode, func3, rd, rs1, symbol +@itemx B type: .insn s opcode, func3, rd, simm12(rs1) @verbatim -+--------------+-----+-----+-------+-------------+-------------+ -| simm21[11:5] | rs2 | rs1 | func3 | simm12[4:0] | opcode | -+--------------+-----+-----+-------+-------------+-------------+ -31 25 20 15 12 7 0 ++------------+--------------+-----+-----+-------+-------------+-------------+--------+ +| simm12[12] | simm12[10:5] | rs2 | rs1 | func3 | simm12[4:1] | simm12[11]] | opcode | ++------------+--------------+-----+-----+-------+-------------+-------------+--------+ +31 30 25 20 15 12 7 0 @end verbatim @item U type: .insn u opcode, rd, simm20 @@ -359,6 +362,7 @@ with the @samp{.insn} pseudo directive: @end verbatim @item UJ type: .insn uj opcode, rd, symbol +@itemx J type: .insn j opcode, rd, symbol @verbatim +------------+--------------+------------+---------------+----+-------------+ | simm20[20] | simm20[10:1] | simm20[11] | simm20[19:12] | rd | opcode | |