mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 02:03:56 -06:00
accel/tcg: Introduce tb_pc and log_pc
The availability of tb->pc will shortly be conditional. Introduce accessor functions to minimize ifdefs. Pass around a known pc to places like tcg_gen_code, where the caller must already have the value. Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
This commit is contained in:
parent
e4fdf9df5b
commit
fbf59aad17
21 changed files with 82 additions and 61 deletions
|
@ -49,7 +49,7 @@ static void hppa_cpu_synchronize_from_tb(CPUState *cs,
|
|||
HPPACPU *cpu = HPPA_CPU(cs);
|
||||
|
||||
#ifdef CONFIG_USER_ONLY
|
||||
cpu->env.iaoq_f = tb->pc;
|
||||
cpu->env.iaoq_f = tb_pc(tb);
|
||||
cpu->env.iaoq_b = tb->cs_base;
|
||||
#else
|
||||
/* Recover the IAOQ values from the GVA + PRIV. */
|
||||
|
@ -59,7 +59,7 @@ static void hppa_cpu_synchronize_from_tb(CPUState *cs,
|
|||
int32_t diff = cs_base;
|
||||
|
||||
cpu->env.iasq_f = iasq_f;
|
||||
cpu->env.iaoq_f = (tb->pc & ~iasq_f) + priv;
|
||||
cpu->env.iaoq_f = (tb_pc(tb) & ~iasq_f) + priv;
|
||||
if (diff) {
|
||||
cpu->env.iaoq_b = cpu->env.iaoq_f + diff;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue