Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update qemu version to v8.0.4 #120

Merged
merged 9 commits into from
Oct 25, 2023
Merged

Conversation

crazy-max
Copy link
Collaborator

@crazy-max crazy-max commented Dec 17, 2022

changelog: https://wiki.qemu.org/ChangeLog/8.0

notable changes:

  • QEMU 8.0 now supports Xen guests under KVM when running on the Linux 5.12 kernel or newer.
  • System emulation on 32-bit x86 hosts has been deprecated. The 32-bit x86 host support for system emulation is deemed no longer effective.
  • Due to Intel HAXM being retired, the "-accel hax" option has been deprecated.
  • New ARM emulated CPU types of Cortex-A55 and Cortex-R52.
  • QEMU 8.0 on RISC-V supports a number of new extensions like smstateen, Zawrs, the T-Head vendor extensions, Svadu, Zicond, and Zicbiom, ZCicboz, and Zicbop. QEMU 8.0 is also now capable of supporting ACPI on RISC-V.
  • QEMU 8.0 adds a new CPU model for Intel Sapphire Rapids.
  • A new "ide-cf" option for emulating a CompactFlash card block device.
  • Support for the F13 and F14 keys have been added for input handling.
  • Experimental VFIO migration support for the v2 VFIO migration protocol while removing v1 protocol support.

changelog: https://wiki.qemu.org/ChangeLog/7.2

notable changes:

  • QEMU for x86/x86_64 now supports the CORE_THREAD_COUNT MSR.
  • Support for passing a random seed to the Linux kernel when booted using the "-kernel" argument.
  • The Tiny Code Generator (TCG) has performance improvements in full system emulation mode, fixes for its SSE implementation, and TCG now supports AVX / AVX2 / F16C / FMA3 / VAES instructions.
  • Support for saving/restoring the XSAVE state in signal frames for the user-mode emulation code on x86_64.
  • QEMU with 9pfs has a "massive general performance improvement" as much as 6~12x better performance. This massive speed-up in the QEMU 9pfs code comes from making use of a GHashTable for the FID table. With the change by Linus Heckemann, "This change uses a hashtable for this instead, significantly improving the performance of the 9p filesystem. The runtime of NixOS's simple installer test, which copies ~122k files totalling ~1.8GiB from 9p, decreased by a factor of about 10."
  • QEMU's RISC-V code now supports Zihintpause, disas support for vector instructions, promoting zmmul out of being experimental, improvements to the debugger spec, and other RISC-V improvements.
  • QEMU for s390x now supports SHA-512 via KIMD/KLMD instructions, fixed emulation of LZRF and VISTR instructions, and implementing other features.
  • Stability improvements to the QEMU OpenRISC code as well as performance improvements.
  • QEMU on Arm now supports emulating Enhanced Translation Synchronization, PMU Extensions v3.5, guest translation granule size, HAFDBS, and E0PD. The Arm Cortex-A35 CPU type can also now be emulated.
  • LoongArch ISA support improvements as well as a number of machine additions.
  • Big endian 32-bit MIPS hosts have been deprecated.

@crazy-max crazy-max force-pushed the update-qemu branch 6 times, most recently from 8103a93 to 71097f4 Compare December 17, 2022 08:50
@crazy-max crazy-max force-pushed the update-qemu branch 7 times, most recently from e4d02bf to 928fc72 Compare May 3, 2023 19:34
@crazy-max crazy-max changed the title update qemu version to v7.2.0 update qemu version to v8.0.0 May 3, 2023
@crazy-max crazy-max force-pushed the update-qemu branch 6 times, most recently from ef63c28 to 7488927 Compare May 4, 2023 18:39
@crazy-max crazy-max changed the title update qemu version to v8.0.0 update qemu version to v8.0.2 Jun 18, 2023
@crazy-max crazy-max force-pushed the update-qemu branch 2 times, most recently from 35b0049 to 19ad4ea Compare June 18, 2023 21:48
test/test.bats Outdated
@@ -83,7 +83,7 @@ execdirect() {
@test "shebang-direct" {
execdirect ./shebang.sh foo bar1
assert_success
assert_output "./printargs ./shebang.sh foo bar1"
assert_output "./printargs /work/shebang.sh foo bar1"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tonistiigi About this change: https://github.com/tonistiigi/binfmt/actions/runs/5305194882/jobs/9602044053#step:4:385

#43 15.22 not ok 11 shebang-direct
#43 15.22 # (from function `assert_output' in file bats-assert/src/assert.bash, line 239,
#43 15.22 #  in test file test.bats, line 86)
#43 15.23 #   `assert_output "./printargs ./shebang.sh foo bar1"' failed
#43 15.23 #
#43 15.23 # -- output differs --
#43 15.23 # expected : ./printargs ./shebang.sh foo bar1
#43 15.23 # actual   : ./printargs /work/shebang.sh foo bar1
#43 15.23 # --
#43 15.23 #

linux-user now resolves the full path name of the started process at startup. See qemu/qemu@258bec3

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this a breaking change (at least for the direct mode without -P)? What if the program reads its args[0], it wouldn't expect that the value gets modified.

If this is how it behaves with QEMU_PRESERVE_ARGV0 in kernel then it just looks plain wrong. If it is just a problem with our direct exec patches then the patches may need updates.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hdeller are we missing some context in here?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My change just makes the emulated binary work the same way as a native program would. This means /proc/self/exe will return the currently running executable. I don't think my patch modified args[] values.
I think if you would run your testsuite in the ./work directory you wouldn't see that changed.

@sando38
Copy link

sando38 commented Aug 30, 2023

Hello there,
Qemu is now available as version 8.1, which includes a bug fix, which solves an issue with our build pipelines.
Do you plan to release a new version of your Docker image soon, including version 8.1?
Thanks in advance!

@tonistiigi
Copy link
Owner

My suggestion is to go ahead with this and follow up with 8.1 BUT not update the latest tag before we have the args CI issue figured out. @crazy-max Do we need release pipeline changes for this?

@crazy-max crazy-max changed the title update qemu version to v8.0.2 update qemu version to v8.0.4 Sep 8, 2023
@crazy-max
Copy link
Collaborator Author

Do we need release pipeline changes for this?

We can skip latest:

latest:
description: 'Create latest tag'
required: true
default: 'false'

image

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
linux-user now resolves the full path name of the started
process: qemu/qemu@258bec3.
we should fix our patches in a follow-up.

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
@crazy-max crazy-max merged commit bc8ed90 into tonistiigi:master Oct 25, 2023
13 checks passed
@crazy-max crazy-max deleted the update-qemu branch October 25, 2023 10:15
@crazy-max
Copy link
Collaborator Author

Can be tested with tonistiigi/binfmt:qemu-v8.0.4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants