diff options
author | Christian Limpach <Christian.Limpach@xensource.com> | 2007-05-09 14:17:15 +0100 |
---|---|---|
committer | Christian Limpach <Christian.Limpach@xensource.com> | 2007-05-09 14:17:15 +0100 |
commit | c74a52ad23410989950f58f905f0c9f392cb2acf (patch) | |
tree | 449594c4dfc73573587fcb60606fd2e06ad395a1 /tools/ioemu/exec-all.h | |
parent | 15f6eaada976ef05ea329db34f599619907ecedc (diff) | |
download | xen-c74a52ad23410989950f58f905f0c9f392cb2acf.tar.gz xen-c74a52ad23410989950f58f905f0c9f392cb2acf.tar.bz2 xen-c74a52ad23410989950f58f905f0c9f392cb2acf.zip |
[ioemu] Update to qemu 0.90.
Signed-off-by: Christian Limpach <Christian.Limpach@xensource.com>
Diffstat (limited to 'tools/ioemu/exec-all.h')
-rw-r--r-- | tools/ioemu/exec-all.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/tools/ioemu/exec-all.h b/tools/ioemu/exec-all.h index eb4fa76b6c..91d8cf7c97 100644 --- a/tools/ioemu/exec-all.h +++ b/tools/ioemu/exec-all.h @@ -196,9 +196,19 @@ typedef struct TranslationBlock { struct TranslationBlock *jmp_first; } TranslationBlock; +static inline unsigned int tb_jmp_cache_hash_page(target_ulong pc) +{ + target_ulong tmp; + tmp = pc ^ (pc >> (TARGET_PAGE_BITS - TB_JMP_PAGE_BITS)); + return (tmp >> TB_JMP_PAGE_BITS) & TB_JMP_PAGE_MASK; +} + static inline unsigned int tb_jmp_cache_hash_func(target_ulong pc) { - return (pc ^ (pc >> TB_JMP_CACHE_BITS)) & (TB_JMP_CACHE_SIZE - 1); + target_ulong tmp; + tmp = pc ^ (pc >> (TARGET_PAGE_BITS - TB_JMP_PAGE_BITS)); + return (((tmp >> TB_JMP_PAGE_BITS) & TB_JMP_PAGE_MASK) | + (tmp & TB_JMP_ADDR_MASK)); } static inline unsigned int tb_phys_hash_func(unsigned long pc) |