qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 00/19] accel: Introduce AccelvCPUState opaque structure
@ 2021-03-03 18:22 Philippe Mathieu-Daudé
  2021-03-03 18:22 ` [PATCH 01/19] target/i386/hvf: Use boolean value for vcpu_dirty Philippe Mathieu-Daudé
                   ` (19 more replies)
  0 siblings, 20 replies; 27+ messages in thread
From: Philippe Mathieu-Daudé @ 2021-03-03 18:22 UTC (permalink / raw)
  To: qemu-devel
  Cc: Peter Maydell, Cornelia Huck, kvm, David Hildenbrand, haxm-team,
	Colin Xu, Halil Pasic, Christian Borntraeger, Claudio Fontana,
	Philippe Mathieu-Daudé, Thomas Huth, Eduardo Habkost,
	Richard Henderson, Greg Kurz, Cameron Esfahani, Roman Bolshakov,
	qemu-arm, Sunil Muthuswamy, David Gibson, Marcelo Tosatti,
	qemu-s390x, qemu-ppc, Wenchao Wang, Paolo Bonzini

Hi,

This series introduces the 'AccelvCPUState' which is forward
declared opaque in "cpu.h", then each accelerator define it.

The opaque CPUState::accel_vcpu pointer is shared by all
accelerators (not a problem because there can be at most
one accelerator per vCPU).

Series is organized as:
- preliminary trivial cleanups
- introduce AccelvCPUState
- move WHPX fields (build-tested)
- move HAX fields (not tested)
- move KVM fields (build-tested)
- move HVF fields (not tested)

For now vcpu_dirty is still shared in CPUState.

Sending as RFC to see if it is worthwhile.

Regards,

Phil.

Philippe Mathieu-Daudé (19):
  target/i386/hvf: Use boolean value for vcpu_dirty
  target/s390x/kvm: Simplify debug code
  target/s390x/kvm: Reduce deref by declaring 'struct kvm_run' on stack
  cpu: Croup accelerator-specific fields altogether
  cpu: Introduce AccelvCPUState opaque structure
  accel/whpx: Add typedef for 'struct whpx_vcpu'
  accel/whpx: Rename struct whpx_vcpu -> AccelvCPUState
  accel/whpx: Use 'accel_vcpu' generic pointer
  accel/hax: Add typedef for 'struct hax_vcpu_state'
  accel/hax: Use 'accel_vcpu' generic pointer
  accel/kvm: Introduce kvm_vcpu_state() helper
  accel/kvm: Use kvm_vcpu_state() when possible
  accel/kvm: Declare and allocate AccelvCPUState struct
  accel/kvm: Move the 'kvm_fd' field to AccelvCPUState
  accel/kvm: Move the 'kvm_state' field to AccelvCPUState
  accel/kvm: Move the 'kvm_run' field to AccelvCPUState
  accel/hvf: Reduce deref by declaring 'hv_vcpuid_t hvf_fd' on stack
  accel/hvf: Declare and allocate AccelvCPUState struct
  accel/hvf: Move the 'hvf_fd' field to AccelvCPUState

 include/hw/core/cpu.h         |  17 +--
 include/sysemu/kvm.h          |   2 +
 include/sysemu/kvm_int.h      |   9 ++
 target/i386/hax/hax-i386.h    |  10 +-
 target/i386/hvf/hvf-i386.h    |   4 +
 target/i386/hvf/vmx.h         |  28 +++--
 accel/kvm/kvm-all.c           |  44 ++++---
 hw/s390x/pv.c                 |   3 +-
 target/arm/kvm.c              |   2 +-
 target/arm/kvm64.c            |  12 +-
 target/i386/cpu.c             |   4 +-
 target/i386/hax/hax-all.c     |  22 ++--
 target/i386/hax/hax-posix.c   |   4 +-
 target/i386/hax/hax-windows.c |   4 +-
 target/i386/hvf/hvf.c         | 118 +++++++++---------
 target/i386/hvf/x86.c         |  28 ++---
 target/i386/hvf/x86_descr.c   |  32 +++--
 target/i386/hvf/x86_emu.c     |  62 +++++-----
 target/i386/hvf/x86_mmu.c     |   4 +-
 target/i386/hvf/x86_task.c    |  14 ++-
 target/i386/hvf/x86hvf.c      | 227 +++++++++++++++++-----------------
 target/i386/kvm/kvm.c         |  36 +++---
 target/i386/whpx/whpx-all.c   |  34 ++---
 target/ppc/kvm.c              |  16 +--
 target/s390x/kvm.c            | 148 +++++++++++-----------
 25 files changed, 466 insertions(+), 418 deletions(-)

-- 
2.26.2




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

end of thread, other threads:[~2021-03-04 16:46 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-03-03 18:22 [RFC PATCH 00/19] accel: Introduce AccelvCPUState opaque structure Philippe Mathieu-Daudé
2021-03-03 18:22 ` [PATCH 01/19] target/i386/hvf: Use boolean value for vcpu_dirty Philippe Mathieu-Daudé
2021-03-03 18:22 ` [PATCH 02/19] target/s390x/kvm: Simplify debug code Philippe Mathieu-Daudé
2021-03-04  6:24   ` Thomas Huth
2021-03-04 16:05   ` Cornelia Huck
2021-03-03 18:22 ` [PATCH 03/19] target/s390x/kvm: Reduce deref by declaring 'struct kvm_run' on stack Philippe Mathieu-Daudé
2021-03-03 18:22 ` [PATCH 04/19] cpu: Croup accelerator-specific fields altogether Philippe Mathieu-Daudé
2021-03-04 13:26   ` Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 05/19] cpu: Introduce AccelvCPUState opaque structure Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 06/19] accel/whpx: Add typedef for 'struct whpx_vcpu' Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 07/19] accel/whpx: Rename struct whpx_vcpu -> AccelvCPUState Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 08/19] accel/whpx: Use 'accel_vcpu' generic pointer Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 09/19] accel/hax: Add typedef for 'struct hax_vcpu_state' Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 10/19] accel/hax: Use 'accel_vcpu' generic pointer Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 11/19] accel/kvm: Introduce kvm_vcpu_state() helper Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 12/19] accel/kvm: Use kvm_vcpu_state() when possible Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 13/19] accel/kvm: Declare and allocate AccelvCPUState struct Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 14/19] accel/kvm: Move the 'kvm_fd' field to AccelvCPUState Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 15/19] accel/kvm: Move the 'kvm_state' " Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 16/19] accel/kvm: Move the 'kvm_run' " Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 17/19] accel/hvf: Reduce deref by declaring 'hv_vcpuid_t hvf_fd' on stack Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 18/19] accel/hvf: Declare and allocate AccelvCPUState struct Philippe Mathieu-Daudé
2021-03-03 18:22 ` [RFC PATCH 19/19] accel/hvf: Move the 'hvf_fd' field to AccelvCPUState Philippe Mathieu-Daudé
2021-03-04 13:56 ` [RFC PATCH 00/19] accel: Introduce AccelvCPUState opaque structure Paolo Bonzini
2021-03-04 14:54   ` Philippe Mathieu-Daudé
2021-03-04 15:40     ` Paolo Bonzini
2021-03-04 16:42       ` Philippe Mathieu-Daudé

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