[SOLVED] SSE4.2 on AMD Epyc

saint_antone

Member
Sep 11, 2021
19
1
8
54
I have a baremetal that has an AMD Epyc CPU. I need to run an application that relies on SSE4.2 and does not work if it does not find SSE4.2 support.

Is there any way we can enable the emulation of SSE4.2 for a particular virtual machine so that the application will not fail when detecting hardware support for SSE 4.2?

My PVE version is 7.4-3.
 
Afaik all Zen CPUs should have SSE4.2 onboard. Did you try to set the VM‘s CPU type to „Host“?
 
@cwt - Would setting the CPU type to "host" allow the baremetal's CPU to be used directly by the virtual machine? Are there any risks to using this option, especially to other virtual machines that are hosted on the same baremetal?
 
@cwt - Would setting the CPU type to "host" allow the baremetal's CPU to be used directly by the virtual machine? Are there any risks to using this option, especially to other virtual machines that are hosted on the same baremetal?
There is no way how a VM could use the physical CPU directly. It still uses a virtual CPU. But by setting it to "host" the virtual CPU is allowed to use all the instruction sets the hosts CPU offers.
Downside is that the VM isn't be that portable anymore. So if you want to migrate it between nodes with different hardware this might not be the best option. Also see the wiki: https://pve.proxmox.com/wiki/Qemu/KVM_Virtual_Machines#qm_virtual_machines_settings

CPU Type​

QEMU can emulate a number different of CPU types from 486 to the latest Xeon processors. Each new processor generation adds new features, like hardware assisted 3d rendering, random number generation, memory protection, etc … Usually you should select for your VM a processor type which closely matches the CPU of the host system, as it means that the host CPU features (also called CPU flags ) will be available in your VMs. If you want an exact match, you can set the CPU type to host in which case the VM will have exactly the same CPU flags as your host system.
This has a downside though. If you want to do a live migration of VMs between different hosts, your VM might end up on a new system with a different CPU type. If the CPU flags passed to the guest are missing, the qemu process will stop. To remedy this QEMU has also its own CPU type kvm64, that Proxmox VE uses by defaults. kvm64 is a Pentium 4 look a like CPU type, which has a reduced CPU flags set, but is guaranteed to work everywhere.
In short, if you care about live migration and moving VMs between nodes, leave the kvm64 default. If you don’t care about live migration or have a homogeneous cluster where all nodes have the same CPU, set the CPU type to host, as in theory this will give your guests maximum performance.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!