Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: qemu/qemu
base: ab7252279727
Choose a base ref
...
head repository: qemu/qemu
compare: 2d786cdffa7d
Choose a head ref
  • 12 commits
  • 28 files changed
  • 2 contributors

Commits on May 31, 2023

  1. *-user: remove the guest_user_syscall tracepoints

    This is pure duplication now. Both bsd-user and linux-user have
    builtin strace support and we can also track syscalls via the plugins
    system.
    
    Reviewed-by: Warner Losh <imp@bsdimp.com>
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-2-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-2-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    64c538e View commit details
    Browse the repository at this point in the history
  2. trace-events: remove the remaining vcpu trace events

    While these are all in helper functions being designated vcpu events
    complicates the removal of the dynamic vcpu state code. TCG plugins
    allow you to instrument vcpu_[init|exit|idle].
    
    We rename cpu_reset and make it a normal trace point.
    
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-3-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-3-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    24f1503 View commit details
    Browse the repository at this point in the history
  3. trace: remove vcpu_id from the TraceEvent structure

    This does involve temporarily stubbing out some helper functions
    before we excise the rest of the code.
    
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-4-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-4-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    3204527 View commit details
    Browse the repository at this point in the history
  4. scripts/qapi: document the tool that generated the file

    This makes it a little easier for developers to find where things
    where being generated.
    
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Reviewed-by: Markus Armbruster <armbru@redhat.com>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-5-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-5-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    3aa7977 View commit details
    Browse the repository at this point in the history
  5. docs/deprecated: move QMP events bellow QMP command section

    Also rename the section to make the fact this is part of the
    management protocol even clearer.
    
    Suggested-by: Markus Armbruster <armbru@redhat.com>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-6-alex.bennee@linaro.org
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    ab13c09 View commit details
    Browse the repository at this point in the history
  6. qapi: make the vcpu parameters deprecated for 8.1

    I don't think I can remove the parameters directly but certainly mark
    them as deprecated.
    
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-7-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-6-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    f394461 View commit details
    Browse the repository at this point in the history
  7. trace: remove code that depends on setting vcpu

    Now we no longer have any events that are for vcpus we can start
    excising the code from the trace control. As the vcpu parameter is
    encoded as part of QMP we just stub out the has_vcpu/vcpu parameters
    rather than alter the API.
    
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-8-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-7-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    de0190f View commit details
    Browse the repository at this point in the history
  8. trace: remove control-vcpu.h

    Now we no longer have vcpu controlled trace events we can excise the
    code that allows us to query its status.
    
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-9-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-8-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    dd109ea View commit details
    Browse the repository at this point in the history
  9. tcg: remove the final vestiges of dstate

    Now we no longer have dynamic state affecting things we can remove the
    additional fields in cpu.h and simplify the TB hash calculation.
    
    For the benchmark:
    
        hyperfine -w 2 -m 20 \
          "./arm-softmmu/qemu-system-arm -cpu cortex-a15 \
            -machine type=virt,highmem=off \
            -display none -m 2048 \
            -serial mon:stdio \
            -netdev user,id=unet,hostfwd=tcp::2222-:22 \
            -device virtio-net-pci,netdev=unet \
            -device virtio-scsi-pci \
            -blockdev driver=raw,node-name=hd,discard=unmap,file.driver=host_device,file.filename=/dev/zen-disk/debian-bullseye-armhf \
            -device scsi-hd,drive=hd -smp 4 \
            -kernel /home/alex/lsrc/linux.git/builds/arm/arch/arm/boot/zImage \
            -append 'console=ttyAMA0 root=/dev/sda2 systemd.unit=benchmark.service' \
            -snapshot"
    
    It has a marginal effect on runtime, before:
    
      Time (mean ± σ):     26.279 s ±  2.438 s    [User: 41.113 s, System: 1.843 s]
      Range (min … max):   24.420 s … 32.565 s    20 runs
    
    after:
    
      Time (mean ± σ):     24.440 s ±  2.885 s    [User: 34.474 s, System: 2.028 s]
      Range (min … max):   21.663 s … 29.937 s    20 runs
    
    Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1358
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-10-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-9-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    fbc69de View commit details
    Browse the repository at this point in the history
  10. hw/9pfs: use qemu_xxhash4

    No need to pass zeros as we have helpers that do that for us.
    
    Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
    Reviewed-by: Christian Schoenebeck <qemu_oss@crudebyte.com>
    Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Message-id: 20230526165401.574474-11-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-10-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    fc7e011 View commit details
    Browse the repository at this point in the history
  11. accel/tcg: include cs_base in our hash calculations

    We weren't using cs_base in the hash calculations before. Since the
    arm front end moved a chunk of flags in a378206 (target/arm: Move
    mode specific TB flags to tb->cs_base) they comprise of an important
    part of the execution state.
    
    Widen the tb_hash_func to include cs_base and expand to qemu_xxhash8()
    to accommodate it.
    
    My initial benchmark shows very little difference in the
    runtime.
    
    Before:
    
    armhf
    
    ➜  hyperfine -w 2 -m 20 "./arm-softmmu/qemu-system-arm -cpu cortex-a15 -machine type=virt,highmem=off -display none -m 2048 -serial mon:stdio -netdev user,id=unet,hostfwd=tcp::2222-:22 -device virtio-net-pci,netdev=unet -device virtio-scsi-pci -blockdev driver=raw,node-name=hd,discard=unmap,file.driver=host_device,file.filename=/dev/zen-disk/debian-bullseye-armhf -device scsi-hd,drive=hd -smp 4 -kernel /home/alex/lsrc/linux.git/builds/arm/arch/arm/boot/zImage -append 'console=ttyAMA0 root=/dev/sda2 systemd.unit=benchmark.service' -snapshot"
    Benchmark 1: ./arm-softmmu/qemu-system-arm -cpu cortex-a15 -machine type=virt,highmem=off -display none -m 2048 -serial mon:stdio -netdev user,id=unet,hostfwd=tcp::2222-:22 -device virtio-net-pci,netdev=unet -device virtio-scsi-pci -blockdev driver=raw,node-name=hd,discard=unmap,file.driver=host_device,file.filename=/dev/zen-disk/debian-bullseye-armhf -device scsi-hd,drive=hd -smp 4 -kernel /home/alex/lsrc/linux.git/builds/arm/arch/arm/boot/zImage -append 'console=ttyAMA0 root=/dev/sda2 systemd.unit=benchmark.service' -snapshot
      Time (mean ± σ):     24.627 s ±  2.708 s    [User: 34.309 s, System: 1.797 s]
      Range (min … max):   22.345 s … 29.864 s    20 runs
    
    arm64
    
    ➜  hyperfine -w 2 -n 20 "./qemu-system-aarch64 -cpu max,pauth-impdef=on -machine type=virt,virtualization=on,gic-version=3 -display none -serial mon:stdio -netdev user,id=unet,hostfwd=tcp::2222-:22,hostfwd=tcp::1234-:1234 -device virtio-net-pci,netdev=unet -device virtio-scsi-pci -blockdev driver=raw,node-name=hd,discard=unmap,file.driver=host_device,file.filename=/dev/zen-disk/debian-bullseye-arm64 -device scsi-hd,drive=hd -smp 4 -kernel ~/lsrc/linux.git/builds/arm64/arch/arm64/boot/Image.gz -append 'console=ttyAMA0 root=/dev/sda2 systemd.unit=benchmark-pigz.service' -snapshot"
    Benchmark 1: 20
      Time (mean ± σ):     62.559 s ±  2.917 s    [User: 189.115 s, System: 4.089 s]
      Range (min … max):   59.997 s … 70.153 s    10 runs
    
    After:
    
    armhf
    
    Benchmark 1: ./arm-softmmu/qemu-system-arm -cpu cortex-a15 -machine type=virt,highmem=off -display none -m 2048 -serial mon:stdio -netdev user,id=unet,hostfwd=tcp::2222-:22 -device virtio-net-pci,netdev=unet -device virtio-scsi-pci -blockdev driver=raw,node-name=hd,discard=unmap,file.driver=host_device,file.filename=/dev/zen-disk/debian-bullseye-armhf -device scsi-hd,drive=hd -smp 4 -kernel /home/alex/lsrc/linux.git/builds/arm/arch/arm/boot/zImage -append 'console=ttyAMA0 root=/dev/sda2 systemd.unit=benchmark.service' -snapshot
      Time (mean ± σ):     24.223 s ±  2.151 s    [User: 34.284 s, System: 1.906 s]
      Range (min … max):   22.000 s … 28.476 s    20 runs
    
    arm64
    
    hyperfine -w 2 -n 20 "./qemu-system-aarch64 -cpu max,pauth-impdef=on -machine type=virt,virtualization=on,gic-version=3 -display none -serial mon:stdio -netdev user,id=unet,hostfwd=tcp::2222-:22,hostfwd=tcp::1234-:1234 -device virtio-net-pci,netdev=unet -device virtio-scsi-pci -blockdev driver=raw,node-name=hd,discard=unmap,file.driver=host_device,file.filename=/dev/zen-disk/debian-bullseye-arm64 -device scsi-hd,drive=hd -smp 4 -kernel ~/lsrc/linux.git/builds/arm64/arch/arm64/boot/Image.gz -append 'console=ttyAMA0 root=/dev/sda2 systemd.unit=benchmark-pigz.service' -snapshot"
    Benchmark 1: 20
      Time (mean ± σ):     62.769 s ±  1.978 s    [User: 188.431 s, System: 5.269 s]
      Range (min … max):   60.285 s … 66.868 s    10 runs
    
    Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
    Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
    Message-id: 20230526165401.574474-12-alex.bennee@linaro.org
    Message-Id: <20230524133952.3971948-11-alex.bennee@linaro.org>
    Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
    stsquad authored and Stefan Hajnoczi committed May 31, 2023
    Copy the full SHA
    2e7eda5 View commit details
    Browse the repository at this point in the history
  12. Merge tag 'tracing-pull-request' of https://gitlab.com/stefanha/qemu

    …into staging
    
    Pull request
    
    # -----BEGIN PGP SIGNATURE-----
    #
    # iQEzBAABCAAdFiEEhpWov9P5fNqsNXdanKSrs4Grc8gFAmR3pGwACgkQnKSrs4Gr
    # c8i8RAf8CvZEWjXySRer/8pLdGPVxuNDJ2Ju4gbpQ3chW+31T8LhfZ+KUtJnUcgX
    # 43ICKIZTppq7QxXLcty7yqB7O0OlLylDjrU39uSp60qSdxGFpPk3Pu09bvg+rFua
    # k84weSS2BRg6A9BGB7GCiN9IM2TLSCF72Am9ufVUn6kjhTAQr78bxijw+HB/nqXc
    # +F//aEiEV8UMvfK+bPoTB2ZyLDnO50McbyXbpcZ3Mugz8qFqh71ZbxL7VONyPQaa
    # mfWiPUcUvT42iK71hPBMSnn11SmJpjtS5FIrj+eOmnDX5MmECEVc0Cjxrfnu5suT
    # ZPGAloA+1ORXtpjcDt27ub1YzMjq2w==
    # =tuOx
    # -----END PGP SIGNATURE-----
    # gpg: Signature made Wed 31 May 2023 12:47:56 PM PDT
    # gpg:                using RSA key 8695A8BFD3F97CDAAC35775A9CA4ABB381AB73C8
    # gpg: Good signature from "Stefan Hajnoczi <stefanha@redhat.com>" [full]
    # gpg:                 aka "Stefan Hajnoczi <stefanha@gmail.com>" [full]
    
    * tag 'tracing-pull-request' of https://gitlab.com/stefanha/qemu:
      accel/tcg: include cs_base in our hash calculations
      hw/9pfs: use qemu_xxhash4
      tcg: remove the final vestiges of dstate
      trace: remove control-vcpu.h
      trace: remove code that depends on setting vcpu
      qapi: make the vcpu parameters deprecated for 8.1
      docs/deprecated: move QMP events bellow QMP command section
      scripts/qapi: document the tool that generated the file
      trace: remove vcpu_id from the TraceEvent structure
      trace-events: remove the remaining vcpu trace events
      *-user: remove the guest_user_syscall tracepoints
    
    Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
    rth7680 committed May 31, 2023
    Copy the full SHA
    2d786cd View commit details
    Browse the repository at this point in the history