qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] Trapped instruction encoding support
@ 2020-07-29 11:27 Anup Patel
  2020-07-29 11:27 ` [PATCH 1/3] target/riscv: Optional feature to provide trapped instruction in CSRs Anup Patel
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Anup Patel @ 2020-07-29 11:27 UTC (permalink / raw)
  To: Peter Maydell, Palmer Dabbelt, Alistair Francis, Sagar Karandikar
  Cc: Atish Patra, Anup Patel, qemu-riscv, qemu-devel, Anup Patel

With RISC-V H-extension support, a RISC-V implementation can provide trapped
instruction encoding for almost all traps/exceptions.

For illegal/virtual instruction traps, the instruction encoding is available
in STVAL/MTVAL CSR.

For load/store faults, a transformed encoding of the trapped instruction is
available in MTINST/HTINST CSR.

This series implements optional RISC-V HART feature to provide trapped
instruction encoding in appropriate CSR.

These patches can be found in riscv_trap_insn_v1, branch at:
https://github.com/avpatel/qemu.git

Anup Patel (3):
  target/riscv: Optional feature to provide trapped instruction in CSRs
  target/riscv: Fix write_htinst() implementation
  target/riscv: Update MTINST/HTINST CSR in riscv_cpu_do_interrupt()

 target/riscv/cpu.c        |   7 ++
 target/riscv/cpu.h        |  11 ++-
 target/riscv/cpu_helper.c | 172 +++++++++++++++++++++++++++++++++++++-
 target/riscv/csr.c        |   1 +
 target/riscv/instmap.h    |  41 +++++++++
 target/riscv/translate.c  |  14 +++-
 6 files changed, 241 insertions(+), 5 deletions(-)

-- 
2.25.1



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-08-13 15:53 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-07-29 11:27 [PATCH 0/3] Trapped instruction encoding support Anup Patel
2020-07-29 11:27 ` [PATCH 1/3] target/riscv: Optional feature to provide trapped instruction in CSRs Anup Patel
2020-08-12 22:37   ` Alistair Francis
2020-07-29 11:28 ` [PATCH 2/3] target/riscv: Fix write_htinst() implementation Anup Patel
2020-08-10 22:37   ` Alistair Francis
2020-07-29 11:28 ` [PATCH 3/3] target/riscv: Update MTINST/HTINST CSR in riscv_cpu_do_interrupt() Anup Patel
2020-08-12 23:16   ` Alistair Francis
2020-08-13 15:52     ` Richard Henderson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).