On Mon, 12 Aug 2024 at 14:19, Peter Maydell <peter.mayd...@linaro.org> wrote:
>
> On Mon, 12 Aug 2024 at 14:02, Chris Parker <ch...@parkerfamily.name> wrote:
> > For example, I want to run an application that contains SSE4.1 instructions 
> > on a host machine that doesn't have support for these. If I try to do it 
> > with QEMUt, I'm just given warnings at startup and it doesn't seem that 
> > they have been made available?
> >
> > $ qemu-system-x86_64 -enable-kvm -cpu "host,+ssse3,+sse4.1" -m 256M -smp 1 
> > -boot d -cdrom /home/chris/vmware/iso/TinyCorePure64-15.0.iso -vga qxl 
> > -device AC97
> > qemu-system-x86_64: warning: host doesn't support requested feature: 
> > CPUID.01H:ECX.ssse3 [bit 9]
> > qemu-system-x86_64: warning: host doesn't support requested feature: 
> > CPUID.01H:ECX.sse4.1 [bit 19]
> >
> > Is there something I can change in that command line to make this work, or 
> > why is this impossible?  I know emulation is going to be inefficient and 
> > slow, but my main concern is getting it to actually work at all!
>
> Your command line has "-enable-kvm", which means "don't use emulation,
> use the host CPU's virtualization support to run the guest code directly
> on the host CPU". In this setup, you can only get what the host CPU
> actually has.
>
> If you want pure emulation, then remove the "-enable-kvm" option: the
> default is TCG emulation. You'll also probably need to specify a CPU
> type that isn't "host", because (I think) that CPU type only works
> with KVM.

By the way, just to clarify -- this will mean that absolutely
everything will be emulated: your whole guest OS and every
program running under it. There's no way to have "run fast
using the real CPU for the instructions that it does have,
and emulate only the parts that it is missing" with QEMU.

-- PMM

Reply via email to