Re: performance with guests running 2.4 kernels (specifically RHEL3)

David S. Ahern
2008-04-23T16:39:30Z

Avi Kivity wrote:
>
> Ah! The flood detector is not seeing the access through the
> kmap_atomic() pte, because that access has gone through the emulator.
> last_updated_pte_accessed(vcpu) will never return true.
>
> Can you verify that last_updated_pte_accessed(vcpu) indeed always
> returns false?
>

It returns both true and false. I added a tracer to kvm_mmu_pte_write() to dump
the rc of last_updated_pte_accessed(vcpu). ie.,
pte_access = last_updated_pte_accessed(vcpu);
KVMTRACE_1D(PTE_ACCESS, vcpu, (u32) pte_access, handler);

A sample:

(+ 4488) VMEXIT [ exitcode = 0x00000000, rip = 0x00000000 c016104a ]
(+ 0) PAGE_FAULT [ errorcode = 0x0000000b, virt = 0x00000000 fffb63b0 ]
(+ 2480) PAGE_FAULT1 [ write_count = 0 ]
(+ 424) PAGE_FAULT2 [ level = 2 metaphysical = 0 access 0x00000007 ]
(+ 51672) PAGE_FAULT3
(+ 472) PAGE_FAULT4
(+ 704) PAGE_FAULT5 [ shadow_ent = 0x80000001 2dfb5043 ]
(+ 1496) VMENTRY
(+ 4568) VMEXIT [ exitcode = 0x00000000, rip = 0x00000000 c01610e7 ]
(+ 0) PAGE_FAULT [ errorcode = 0x00000003, virt = 0x00000000 c0009db4 ]
(+ 2352) PAGE_FAULT1 [ write_count = 0 ]
(+ 728) PAGE_FAULT5 [ shadow_ent = 0x00000001 91409041 ]
(+ 0) PTE_WRITE [ gpa = 0x00000000 00009db4 gpte = 0x00000000 41fb5363 ]
(+ 0) PTE_ACCESS [ pte_access = 1 ]
(+ 6864) VMENTRY
(+ 3896) VMEXIT [ exitcode = 0x00000000, rip = 0x00000000 c01610ee ]
(+ 0) PAGE_FAULT [ errorcode = 0x00000003, virt = 0x00000000 c0009db0 ]
(+ 2376) PAGE_FAULT1 [ write_count = 1 ]
(+ 720) PAGE_FAULT5 [ shadow_ent = 0x00000001 91409041 ]
(+ 0) PTE_WRITE [ gpa = 0x00000000 00009db0 gpte = 0x00000000 00000000 ]
(+ 0) PTE_ACCESS [ pte_access = 0 ]
(+ 12344) VMENTRY
(+ 4688) VMEXIT [ exitcode = 0x00000000, rip = 0x00000000 c016127c ]
(+ 0) PAGE_FAULT [ errorcode = 0x00000003, virt = 0x00000000 c0009db4 ]
(+ 2416) PAGE_FAULT1 [ write_count = 2 ]
(+ 792) PAGE_FAULT5 [ shadow_ent = 0x00000001 91409043 ]
(+ 1128) VMENTRY
(+ 4512) VMEXIT [ exitcode = 0x00000000, rip = 0x00000000 c016104a ]
(+ 0) PAGE_FAULT [ errorcode = 0x0000000b, virt = 0x00000000 fffb63b0 ]
(+ 2448) PAGE_FAULT1 [ write_count = 0 ]
(+ 448) PAGE_FAULT2 [ level = 2 metaphysical = 0 access 0x00000007 ]
(+ 51520) PAGE_FAULT3
(+ 432) PAGE_FAULT4
(+ 696) PAGE_FAULT5 [ shadow_ent = 0x80000001 2df5a043 ]
(+ 1480) VMENTRY

david

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.