RISC-V: Add Zawrs ISA extension support
commit260b594d8a8f74198b9b250e9fada7fc43c6f03e
authorChristoph Muellner <christoph.muellner@vrull.eu>
Wed, 5 Oct 2022 14:49:48 +0000 (5 16:49 +0200)
committerAlistair Francis <alistair.francis@wdc.com>
Fri, 6 Jan 2023 00:42:55 +0000 (6 10:42 +1000)
tree24b15c94b24aa0004ab7e051fdce0bc8e8a5047a
parent0ff430a5b10db884d6dd6cde930b4e73283b7507
RISC-V: Add Zawrs ISA extension support

This patch adds support for the Zawrs ISA extension.
Given the current (incomplete) implementation of reservation sets
there seems to be no way to provide a full emulation of the WRS
instruction (wake on reservation set invalidation or timeout or
interrupt). Therefore, we just exit the TB and return to the main loop.

The specification can be found here:
  https://github.com/riscv/riscv-zawrs/blob/main/zawrs.adoc

Note, that the Zawrs extension is frozen, but not ratified yet.

Changes since v3:
* Remove "RFC" since the extension is frozen
* Rebase on master and fix integration issues
* Fix entry ordering in extension list

Changes since v2:
* Rebase on master and resolve conflicts
* Adjustments according to a specification change
* Inline REQUIRE_ZAWRS() since it has only one user

Changes since v1:
* Adding zawrs to the ISA string that is passed to the kernel

Signed-off-by: Christoph Müllner <christoph.muellner@vrull.eu>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-Id: <20221005144948.3421504-1-christoph.muellner@vrull.eu>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
target/riscv/cpu.c
target/riscv/cpu.h
target/riscv/insn32.decode
target/riscv/insn_trans/trans_rvzawrs.c.inc [new file with mode: 0644]
target/riscv/translate.c