qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/6] riscv: RVA22U64 profile support
@ 2023-10-20 22:39 Daniel Henrique Barboza
  2023-10-20 22:39 ` [PATCH v3 1/6] target/riscv: add rva22u64 profile definition Daniel Henrique Barboza
                   ` (5 more replies)
  0 siblings, 6 replies; 23+ messages in thread
From: Daniel Henrique Barboza @ 2023-10-20 22:39 UTC (permalink / raw)
  To: qemu-devel
  Cc: qemu-riscv, alistair.francis, bmeng, liweiwei, zhiwei_liu, palmer,
	Daniel Henrique Barboza

Based-on: 20231017221226.136764-1-dbarboza@ventanamicro.com
("[PATCH v2 0/6] riscv: zicntr/zihpm flags and disable support")

Hi,

The most notable change in this new version is that we're back to
enabling/disabling profile extensions during the property set()
callback, instead of doing an extra step during realize(), to give more
predictability on how profiles can interact with each other.

In the previous version profiles would be committed based on a fixed
internal order. This time they'll be evaluated via the common
left-to-right ordering we're used to in QEMU. This means that these
two configurations are different:

-cpu rv64,profileA=true,profileB=false
"enable all mandatory extensions of profile A, then disable all
mandatory extensions of profile B"

-cpu rv64,profileB=false,profileA=true
"disable all mandatory extensions of profile B, then enable all
mandatory extensions of profile A"

We're also adding an user warning if a profile is disabled. Between
implementing profile disablement (disable all its mandatory extensions)
versus not implementing it and having a flag that does nothing if the
user set it to 'off', we're choosing the least of two ills with the
former. However, given that it is a very niche feature that is hard to
use it right and very easy to do something silly, an user warning is
appropriate.

Series is based on top of the zicntr/zihpm implementation series since
they're both part of the rva22u64 profile.

Patches missing acks: 3, 6

Changes from v2:
- patches 1 and 2 from v2: moved to a separated series
- patches 6, 9 and 10 from v2: dropped
- patch 3:
  - use the set() callback to enable/disable mandatory profile
    extensions
- patch 6:
   - handle profile MISA bits in the profile set() callback
- v2 link: https://lore.kernel.org/qemu-riscv/20231006132134.1135297-1-dbarboza@ventanamicro.com/


Daniel Henrique Barboza (6):
  target/riscv: add rva22u64 profile definition
  target/riscv/kvm: add 'rva22u64' flag as unavailable
  target/riscv/tcg: add user flag for profile support
  target/riscv/tcg: add MISA user options hash
  target/riscv/tcg: add riscv_cpu_write_misa_bit()
  target/riscv/tcg: handle profile MISA bits

 target/riscv/cpu.c         |  20 +++++++
 target/riscv/cpu.h         |  12 ++++
 target/riscv/kvm/kvm-cpu.c |   7 ++-
 target/riscv/tcg/tcg-cpu.c | 118 ++++++++++++++++++++++++++++++++-----
 4 files changed, 142 insertions(+), 15 deletions(-)

-- 
2.41.0



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

end of thread, other threads:[~2023-10-28  9:33 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-20 22:39 [PATCH v3 0/6] riscv: RVA22U64 profile support Daniel Henrique Barboza
2023-10-20 22:39 ` [PATCH v3 1/6] target/riscv: add rva22u64 profile definition Daniel Henrique Barboza
2023-10-25  6:22   ` LIU Zhiwei
2023-10-25 13:14     ` Daniel Henrique Barboza
2023-10-20 22:39 ` [PATCH v3 2/6] target/riscv/kvm: add 'rva22u64' flag as unavailable Daniel Henrique Barboza
2023-10-25  6:28   ` LIU Zhiwei
2023-10-20 22:39 ` [PATCH v3 3/6] target/riscv/tcg: add user flag for profile support Daniel Henrique Barboza
2023-10-23  8:16   ` Andrew Jones
2023-10-23 17:00     ` Daniel Henrique Barboza
2023-10-23 17:35       ` Andrew Jones
2023-10-23 17:54         ` Daniel Henrique Barboza
2023-10-26 14:36         ` Andrea Bolognani
2023-10-26 15:14           ` Andrew Jones
2023-10-26 17:36             ` Andrea Bolognani
2023-10-27 17:52               ` Daniel Henrique Barboza
2023-10-28  9:31                 ` Andrew Jones
2023-10-25  6:35   ` LIU Zhiwei
2023-10-20 22:39 ` [PATCH v3 4/6] target/riscv/tcg: add MISA user options hash Daniel Henrique Barboza
2023-10-25  6:45   ` LIU Zhiwei
2023-10-20 22:39 ` [PATCH v3 5/6] target/riscv/tcg: add riscv_cpu_write_misa_bit() Daniel Henrique Barboza
2023-10-25  6:45   ` LIU Zhiwei
2023-10-20 22:39 ` [PATCH v3 6/6] target/riscv/tcg: handle profile MISA bits Daniel Henrique Barboza
2023-10-25  6:46   ` LIU Zhiwei

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).