Plain qemu with the EPYC-Rome model works without any problems. I already get xsave, xsaveopt, xsavec and xsaveerptr with the current focal kernel, which also means that gcc finally uses znver1 (for v3) and znver2 (for Rome) optimizations.
Libvirt would require cherrypicking a number of commits to enable support for all CPU flags currently supported by focal qemu and for the additional AMD flags from the mentioned patched. I currently run a private build in production with the following patches added: https://github.com/libvirt/libvirt/commits/master/src/cpu_map: - cpu_map: Distinguish Cascadelake-Server from Skylake-Server (unrelated, but recommended) - cpu_map: Add pschange-mc-no bit in IA32_ARCH_CAPABILITIES MSR - cpu_map: Request test files update when adding x86 features - cpu_map: Add missing x86 features in 0x7 CPUID leaf - cpu_map: Add missing x86 features in 0x80000008 CPUID leaf Plus the attached patch which defines an EPYC-Rome type (without any tests), so not quite ready for upstream ** Attachment added: "Add-EPYC-ROME-x86-CPU-model" https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1887490/+attachment/5398119/+files/Add-EPYC-ROME-x86-CPU-model -- You received this bug notification because you are a member of Kernel Packages, which is subscribed to linux in Ubuntu. https://bugs.launchpad.net/bugs/1887490 Title: Add/Backport EPYC-v3 and EPYC-Rome CPU model Status in libvirt package in Ubuntu: Incomplete Status in linux package in Ubuntu: Confirmed Status in qemu package in Ubuntu: Fix Released Status in libvirt source package in Focal: Incomplete Status in linux source package in Focal: Confirmed Status in qemu source package in Focal: Incomplete Bug description: Qemu in focal has already support for most (except amd-stibp) flags of this model. Please backport the following patches: https://github.com/qemu/qemu/commit/a16e8dbc043720abcb37fc7dca313e720b4e0f0c https://github.com/qemu/qemu/commit/143c30d4d346831a09e59e9af45afdca0331e819 To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/libvirt/+bug/1887490/+subscriptions -- Mailing list: https://launchpad.net/~kernel-packages Post to : kernel-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~kernel-packages More help : https://help.launchpad.net/ListHelp