Re: [Qemu-devel] [PATCH] cpu: implementing victim TLB for QEMU system emulated TLB

2014-01-23 Thread Xin Tong
On Thu, Jan 23, 2014 at 5:23 AM, Alex Bennée wrote: > > trent.t...@gmail.com writes: > >> This patch adds a victim TLB to the QEMU system mode TLB. >> >> QEMU system mode page table walks are expensive. Taken by running QEMU >> qemu-system-x86_64 system mode on Intel PIN , a TLB miss and walking a

Re: [Qemu-devel] [PATCH] cpu: implementing victim TLB for QEMU system emulated TLB

2014-01-23 Thread Alex Bennée
trent.t...@gmail.com writes: > This patch adds a victim TLB to the QEMU system mode TLB. > > QEMU system mode page table walks are expensive. Taken by running QEMU > qemu-system-x86_64 system mode on Intel PIN , a TLB miss and walking a > 4-level page tables in guest Linux OS takes ~450 X86 instr

Re: [Qemu-devel] [PATCH] cpu: implementing victim TLB for QEMU system emulated TLB

2014-01-22 Thread Richard Henderson
On 01/22/2014 02:40 PM, Xin Tong wrote: > Thank you very much for your comments. I will provide fixes to the > problems you raised and make sure my next patch passes the > checkpatch.pl. I have a question I would like to make sure. After i go > back and fixed the problems with this patch. I need to

Re: [Qemu-devel] [PATCH] cpu: implementing victim TLB for QEMU system emulated TLB

2014-01-22 Thread Xin Tong
Richard. Thank you very much for your comments. I will provide fixes to the problems you raised and make sure my next patch passes the checkpatch.pl. I have a question I would like to make sure. After i go back and fixed the problems with this patch. I need to send another (different) email with t

Re: [Qemu-devel] [PATCH] cpu: implementing victim TLB for QEMU system emulated TLB

2014-01-22 Thread Richard Henderson
On 01/22/2014 06:48 AM, Xin Tong wrote: > +#define TLB_XOR_SWAP(X, Y) do {*X = *X ^ *Y; *Y = *X ^ *Y; *X = *X ^ > *Y;}while(0); First, your patch is line wrapped. You really really really need to follow the directions Peter gave you. Second, using xor to swap values is a cute assembler trick, bu

[Qemu-devel] [PATCH] cpu: implementing victim TLB for QEMU system emulated TLB

2014-01-22 Thread Xin Tong
This patch adds a victim TLB to the QEMU system mode TLB. QEMU system mode page table walks are expensive. Taken by running QEMU qemu-system-x86_64 system mode on Intel PIN , a TLB miss and walking a 4-level page tables in guest Linux OS takes ~450 X86 instructions on average. QEMU system mode TL