qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] virtual pc hash table vs physical pc hash table


From: 陳韋任
Subject: Re: [Qemu-devel] virtual pc hash table vs physical pc hash table
Date: Fri, 20 Jan 2012 14:24:50 +0800
User-agent: Mutt/1.5.21 (2010-09-15)

On Mon, Jan 02, 2012 at 07:11:41AM -0500, Xin Tong wrote:
> In qemu, there is a virtual pc hash table and a physical pc hash
> table. virtual pc hash table is used to find tbs until a context
> switch. and physical pc hash table keeps all the translated tb.
> virtual pc hash table is smaller, accessed with 12 bits and physical
> pc hash table is bigger, accessed with 15 bits. the size in the hash
> tables are the primary reasons for having 2 hash tables ?

  I think not. tb_find_fast use the virtual pc as index to search 
env->tb_jmp_cache,
and check the result of tb_jmp_cache is sane or not. If something goes wrong, it
turns to call tb_find_slow to use physical pc to do a slow search. The size
should not be the reason for having 2 hash tables.

Regards,
chenwj

-- 
Wei-Ren Chen (陳韋任)
Computer Systems Lab, Institute of Information Science,
Academia Sinica, Taiwan (R.O.C.)
Tel:886-2-2788-3799 #1667
Homepage: http://people.cs.nctu.edu.tw/~chenwj



reply via email to

[Prev in Thread] Current Thread [Next in Thread]