mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-09 02:24:58 -06:00
target/cris: Fix use_goto_tb
Do not skip the page check for user-only -- mmap/mprotect can still change page mappings. Only check dc->base.pc_first, not dc->ppc -- the start page is the only one that's relevant. Reviewed-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> Tested-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
parent
1dd09c47f6
commit
06188c8981
1 changed files with 2 additions and 7 deletions
|
@ -524,14 +524,9 @@ static void t_gen_cc_jmp(TCGv pc_true, TCGv pc_false)
|
||||||
gen_set_label(l1);
|
gen_set_label(l1);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline bool use_goto_tb(DisasContext *dc, target_ulong dest)
|
static bool use_goto_tb(DisasContext *dc, target_ulong dest)
|
||||||
{
|
{
|
||||||
#ifndef CONFIG_USER_ONLY
|
return ((dest ^ dc->base.pc_first) & TARGET_PAGE_MASK) == 0;
|
||||||
return (dc->base.pc_first & TARGET_PAGE_MASK) == (dest & TARGET_PAGE_MASK) ||
|
|
||||||
(dc->ppc & TARGET_PAGE_MASK) == (dest & TARGET_PAGE_MASK);
|
|
||||||
#else
|
|
||||||
return true;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void gen_goto_tb(DisasContext *dc, int n, target_ulong dest)
|
static void gen_goto_tb(DisasContext *dc, int n, target_ulong dest)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue