diff options
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | opcodes-rv32b | 70 | ||||
-rw-r--r-- | opcodes-rv64b | 61 |
3 files changed, 132 insertions, 1 deletions
@@ -5,7 +5,7 @@ PK_H := ../riscv-pk/machine/encoding.h ENV_H := ../riscv-tests/env/encoding.h OPENOCD_H := ../riscv-openocd/src/target/riscv/encoding.h -ALL_REAL_ILEN32_OPCODES := opcodes-rv32i opcodes-rv64i opcodes-rv32m opcodes-rv64m opcodes-rv32a opcodes-rv64a opcodes-rv32h opcodes-rv64h opcodes-rv32f opcodes-rv64f opcodes-rv32d opcodes-rv64d opcodes-rv32q opcodes-rv64q opcodes-system +ALL_REAL_ILEN32_OPCODES := opcodes-rv32i opcodes-rv64i opcodes-rv32m opcodes-rv64m opcodes-rv32a opcodes-rv64a opcodes-rv32h opcodes-rv64h opcodes-rv32f opcodes-rv64f opcodes-rv32d opcodes-rv64d opcodes-rv32q opcodes-rv64q opcodes-rv32b opcodes-rv64b opcodes-system ALL_REAL_OPCODES := $(ALL_REAL_ILEN32_OPCODES) opcodes-rvc opcodes-rv32c opcodes-rv64c opcodes-custom opcodes-rvv ALL_OPCODES := opcodes-pseudo $(ALL_REAL_OPCODES) opcodes-rvv-pseudo diff --git a/opcodes-rv32b b/opcodes-rv32b new file mode 100644 index 0000000..bff201a --- /dev/null +++ b/opcodes-rv32b @@ -0,0 +1,70 @@ +andn rd rs1 rs2 31..25=32 14..12=7 6..2=0x0C 1..0=3 +orn rd rs1 rs2 31..25=32 14..12=6 6..2=0x0C 1..0=3 +xnor rd rs1 rs2 31..25=32 14..12=4 6..2=0x0C 1..0=3 + +slo rd rs1 rs2 31..25=16 14..12=1 6..2=0x0C 1..0=3 +sro rd rs1 rs2 31..25=16 14..12=5 6..2=0x0C 1..0=3 +rol rd rs1 rs2 31..25=48 14..12=1 6..2=0x0C 1..0=3 +ror rd rs1 rs2 31..25=48 14..12=5 6..2=0x0C 1..0=3 + +sbclr rd rs1 rs2 31..25=36 14..12=1 6..2=0x0C 1..0=3 +sbset rd rs1 rs2 31..25=20 14..12=1 6..2=0x0C 1..0=3 +sbinv rd rs1 rs2 31..25=52 14..12=1 6..2=0x0C 1..0=3 +sbext rd rs1 rs2 31..25=36 14..12=5 6..2=0x0C 1..0=3 +gorc rd rs1 rs2 31..25=20 14..12=5 6..2=0x0C 1..0=3 +grev rd rs1 rs2 31..25=52 14..12=5 6..2=0x0C 1..0=3 + +sloi rd rs1 31..26=8 shamt 14..12=1 6..2=0x04 1..0=3 +sroi rd rs1 31..26=8 shamt 14..12=5 6..2=0x04 1..0=3 +rori rd rs1 31..26=24 shamt 14..12=5 6..2=0x04 1..0=3 + +sbclri rd rs1 31..26=18 shamt 14..12=1 6..2=0x04 1..0=3 +sbseti rd rs1 31..26=10 shamt 14..12=1 6..2=0x04 1..0=3 +sbinvi rd rs1 31..26=26 shamt 14..12=1 6..2=0x04 1..0=3 +sbexti rd rs1 31..26=18 shamt 14..12=5 6..2=0x04 1..0=3 +gorci rd rs1 31..26=10 shamt 14..12=5 6..2=0x04 1..0=3 +grevi rd rs1 31..26=26 shamt 14..12=5 6..2=0x04 1..0=3 + +cmix rd rs1 rs2 rs3 26..25=3 14..12=1 6..2=0x0C 1..0=3 +cmov rd rs1 rs2 rs3 26..25=3 14..12=5 6..2=0x0C 1..0=3 + +fsl rd rs1 rs2 rs3 26..25=2 14..12=1 6..2=0x0C 1..0=3 +fsr rd rs1 rs2 rs3 26..25=2 14..12=5 6..2=0x0C 1..0=3 +fsri rd rs1 shamt rs3 26=1 14..12=5 6..2=0x04 1..0=3 + +clz rd rs1 31..20=0x600 14..12=1 6..2=0x04 1..0=3 +ctz rd rs1 31..20=0x601 14..12=1 6..2=0x04 1..0=3 +pcnt rd rs1 31..20=0x602 14..12=1 6..2=0x04 1..0=3 +sext.b rd rs1 31..20=0x604 14..12=1 6..2=0x04 1..0=3 +sext.h rd rs1 31..20=0x605 14..12=1 6..2=0x04 1..0=3 + +crc32.b rd rs1 31..20=0x610 14..12=1 6..2=0x04 1..0=3 +crc32.h rd rs1 31..20=0x611 14..12=1 6..2=0x04 1..0=3 +crc32.w rd rs1 31..20=0x612 14..12=1 6..2=0x04 1..0=3 +crc32c.b rd rs1 31..20=0x618 14..12=1 6..2=0x04 1..0=3 +crc32c.h rd rs1 31..20=0x619 14..12=1 6..2=0x04 1..0=3 +crc32c.w rd rs1 31..20=0x61A 14..12=1 6..2=0x04 1..0=3 + +sh1add rd rs1 rs2 31..25=16 14..12=2 6..2=0x0C 1..0=3 +sh2add rd rs1 rs2 31..25=16 14..12=4 6..2=0x0C 1..0=3 +sh3add rd rs1 rs2 31..25=16 14..12=6 6..2=0x0C 1..0=3 + +clmul rd rs1 rs2 31..25=5 14..12=1 6..2=0x0C 1..0=3 +clmulr rd rs1 rs2 31..25=5 14..12=2 6..2=0x0C 1..0=3 +clmulh rd rs1 rs2 31..25=5 14..12=3 6..2=0x0C 1..0=3 +min rd rs1 rs2 31..25=5 14..12=4 6..2=0x0C 1..0=3 +minu rd rs1 rs2 31..25=5 14..12=5 6..2=0x0C 1..0=3 +max rd rs1 rs2 31..25=5 14..12=6 6..2=0x0C 1..0=3 +maxu rd rs1 rs2 31..25=5 14..12=7 6..2=0x0C 1..0=3 + +shfl rd rs1 rs2 31..25=4 14..12=1 6..2=0x0C 1..0=3 +unshfl rd rs1 rs2 31..25=4 14..12=5 6..2=0x0C 1..0=3 +bext rd rs1 rs2 31..25=4 14..12=6 6..2=0x0C 1..0=3 +bdep rd rs1 rs2 31..25=36 14..12=6 6..2=0x0C 1..0=3 +pack rd rs1 rs2 31..25=4 14..12=4 6..2=0x0C 1..0=3 +packu rd rs1 rs2 31..25=36 14..12=4 6..2=0x0C 1..0=3 +packh rd rs1 rs2 31..25=4 14..12=7 6..2=0x0C 1..0=3 +bfp rd rs1 rs2 31..25=36 14..12=7 6..2=0x0C 1..0=3 + +shfli rd rs1 31..25=4 shamtw 14..12=1 6..2=0x04 1..0=3 +unshfli rd rs1 31..25=4 shamtw 14..12=5 6..2=0x04 1..0=3 diff --git a/opcodes-rv64b b/opcodes-rv64b new file mode 100644 index 0000000..59d0172 --- /dev/null +++ b/opcodes-rv64b @@ -0,0 +1,61 @@ +# RV64B additions to RV32B + +bmatflip rd rs1 31..20=0x603 14..12=1 6..2=0x04 1..0=3 +crc32.d rd rs1 31..20=0x613 14..12=1 6..2=0x04 1..0=3 +crc32c.d rd rs1 31..20=0x61B 14..12=1 6..2=0x04 1..0=3 + +bmator rd rs1 rs2 31..25=4 14..12=3 6..2=0x0C 1..0=3 +bmatxor rd rs1 rs2 31..25=36 14..12=3 6..2=0x0C 1..0=3 + +addiwu rd rs1 imm12 14..12=4 6..2=0x06 1..0=3 +slliu.w rd rs1 31..26=2 shamt 14..12=1 6..2=0x06 1..0=3 + +addwu rd rs1 rs2 31..25=5 14..12=0 6..2=0x0E 1..0=3 +subwu rd rs1 rs2 31..25=37 14..12=0 6..2=0x0E 1..0=3 +addu.w rd rs1 rs2 31..25=4 14..12=0 6..2=0x0E 1..0=3 + +slow rd rs1 rs2 31..25=16 14..12=1 6..2=0x0E 1..0=3 +srow rd rs1 rs2 31..25=16 14..12=5 6..2=0x0E 1..0=3 +rolw rd rs1 rs2 31..25=48 14..12=1 6..2=0x0E 1..0=3 +rorw rd rs1 rs2 31..25=48 14..12=5 6..2=0x0E 1..0=3 + +sbclrw rd rs1 rs2 31..25=36 14..12=1 6..2=0x0E 1..0=3 +sbsetw rd rs1 rs2 31..25=20 14..12=1 6..2=0x0E 1..0=3 +sbinvw rd rs1 rs2 31..25=52 14..12=1 6..2=0x0E 1..0=3 +sbextw rd rs1 rs2 31..25=36 14..12=5 6..2=0x0E 1..0=3 +gorcw rd rs1 rs2 31..25=20 14..12=5 6..2=0x0E 1..0=3 +grevw rd rs1 rs2 31..25=52 14..12=5 6..2=0x0E 1..0=3 + +sloiw rd rs1 31..26=8 25=0 shamtw 14..12=1 6..2=0x06 1..0=3 +sroiw rd rs1 31..26=8 25=0 shamtw 14..12=5 6..2=0x06 1..0=3 +roriw rd rs1 31..26=24 25=0 shamtw 14..12=5 6..2=0x06 1..0=3 + +sbclriw rd rs1 31..26=18 25=0 shamtw 14..12=1 6..2=0x06 1..0=3 +sbsetiw rd rs1 31..26=10 25=0 shamtw 14..12=1 6..2=0x06 1..0=3 +sbinviw rd rs1 31..26=26 25=0 shamtw 14..12=1 6..2=0x06 1..0=3 +gorciw rd rs1 31..26=10 25=0 shamtw 14..12=5 6..2=0x06 1..0=3 +greviw rd rs1 31..26=26 25=0 shamtw 14..12=5 6..2=0x06 1..0=3 + +fslw rd rs1 rs2 rs3 26..25=2 14..12=1 6..2=0x0E 1..0=3 +fsrw rd rs1 rs2 rs3 26..25=2 14..12=5 6..2=0x0E 1..0=3 +fsriw rd rs1 shamtw rs3 26..25=2 14..12=5 6..2=0x06 1..0=3 + +clzw rd rs1 31..20=0x600 14..12=1 6..2=0x06 1..0=3 +ctzw rd rs1 31..20=0x601 14..12=1 6..2=0x06 1..0=3 +pcntw rd rs1 31..20=0x602 14..12=1 6..2=0x06 1..0=3 + +sh1addu.w rd rs1 rs2 31..25=16 14..12=2 6..2=0x0E 1..0=3 +sh2addu.w rd rs1 rs2 31..25=16 14..12=4 6..2=0x0E 1..0=3 +sh3addu.w rd rs1 rs2 31..25=16 14..12=6 6..2=0x0E 1..0=3 + +clmulw rd rs1 rs2 31..25=5 14..12=1 6..2=0x0E 1..0=3 +clmulrw rd rs1 rs2 31..25=5 14..12=2 6..2=0x0E 1..0=3 +clmulhw rd rs1 rs2 31..25=5 14..12=3 6..2=0x0E 1..0=3 + +shflw rd rs1 rs2 31..25=4 14..12=1 6..2=0x0E 1..0=3 +unshflw rd rs1 rs2 31..25=4 14..12=5 6..2=0x0E 1..0=3 +bextw rd rs1 rs2 31..25=4 14..12=6 6..2=0x0E 1..0=3 +bdepw rd rs1 rs2 31..25=36 14..12=6 6..2=0x0E 1..0=3 +packw rd rs1 rs2 31..25=4 14..12=4 6..2=0x0E 1..0=3 +packuw rd rs1 rs2 31..25=36 14..12=4 6..2=0x0E 1..0=3 +bfpw rd rs1 rs2 31..25=36 14..12=7 6..2=0x0E 1..0=3 |