[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] OVMF very slow on AMD



On Fri, Jul 15, 2016 at 09:48:31AM -0400, Konrad Rzeszutek Wilk wrote:
> On Thu, Jul 14, 2016 at 04:53:07PM +0100, Anthony PERARD wrote:
> > So, this loop takes about 1 minute on my AMD machine (AMD Opteron(tm)
> > Processor 4284), and less that 1 second on an Intel machine.
> > If I compile OVMF as a 32bit binary, the loop is faster, but still takes
> > about 30s on AMD. (that's true for both OvmfIa32 and OvmfIa32X64 which
> > is 32bit bootstrap, but can start 64bit OS.)
> > Another thing, I tried the same binary (64bit) with KVM, and OVMF seems
> > fast.
> > 
> > 
> > So, any idee of what I could investigate?
> 
> I presume we emulating some operation on AMD but not on Intel.
> 
> However you say xentrace shows nothing - which would imply we are not
> incurring VMEXITs to deal with this. Hmm.. Could it be what we
> expose to the guest (the CPUID flags?) Somehow we are missing one on AMD
> and it takes a slower route?

Since the same binary runs much faster in a KVM guest, I have compared
the procinfo of the guest between KVM and Xen (via /proc/cpuinfo), and
Xen have more flags:

$ dwdiff procinfo_guest_ovmf_kvm procinfo_guest_ovmf_xen
processor       : 0
vendor_id       : AuthenticAMD
cpu family      : [-6-] {+21+}
model           : [-6-] {+1+}
model name      : [-QEMU Virtual CPU version 2.5+-] {+AMD Opteron(tm) Processor 
4284+}
stepping        : [-3-] {+2+}
microcode       : [-0x1000065-] {+0x600063d+}
cpu MHz         : [-3000.034-] {+3000.112+}
cache size      : [-512-] {+2048+} KB
{+physical id   : 0
siblings        : 1
core id         : 0
cpu cores       : 1
apicid          : 0
initial apicid  : 0+}
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu {+vme+} de pse tsc msr pae mce cx8 apic sep mtrr pge mca 
cmov pat pse36 clflush mmx fxsr sse sse2 {+ht+} syscall nx {+mmxext fxsr_opt 
pdpe1gb rdtscp+} lm {+rep_good+} nopl {+extd_apicid+} pni {+pclmulqdq ssse3+} 
cx16 {+sse4_1 sse4_2+} x2apic {+popcnt aes xsave avx+} hypervisor lahf_lm 
{+cr8_legacy abm sse4a misalignsse 3dnowprefetch ibs xop lwp fma4 arat+}
bogomips        : [-6002.07-] {+6002.23+}
TLB size        : [-1024-] {+1536+} 4K pages
clflush size    : 64
cache_alignment : 64
address sizes   : [-40-] {+48+} bits physical, 48 bits virtual
power management:


-- 
Anthony PERARD

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.