From 2ba1eeb62c29d23238b95dc7e9ade3444b49f0a1 Mon Sep 17 00:00:00 2001 From: pbrook Date: Sun, 10 Feb 2008 02:41:15 +0000 Subject: Fix TCG relocation bug (exposed by fault after brcond op). Add FIXME for annother potential bug. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3968 c046a42c-6fe2-441c-8c8c-71466251a162 --- translate-all.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'translate-all.c') diff --git a/translate-all.c b/translate-all.c index 9639612eb7..2000083d85 100644 --- a/translate-all.c +++ b/translate-all.c @@ -187,8 +187,7 @@ int cpu_restore_state(TranslationBlock *tb, s->tb_jmp_offset = NULL; s->tb_next = tb->tb_next; #endif - j = dyngen_code_search_pc(s, (uint8_t *)tc_ptr, - (void *)searched_pc); + j = dyngen_code_search_pc(s, searched_pc - tc_ptr); if (j < 0) return -1; /* now find start of instruction before */ -- cgit v1.2.3