On 1/17/21 5:48 PM, Philippe Mathieu-Daudé wrote: > As cpu_io_recompile() is only called within TCG accelerator > in cputlb.c, declare it locally. > > Signed-off-by: Philippe Mathieu-Daudé <f4...@amsat.org>
It's only used in accel/tcg/cputlb.c, should it be a static function there? > --- > RFC because not sure if other accelerator could implement this. > --- > accel/tcg/internal.h | 2 ++ > include/exec/exec-all.h | 1 - > 2 files changed, 2 insertions(+), 1 deletion(-) > > diff --git a/accel/tcg/internal.h b/accel/tcg/internal.h > index f7e18c3498b..c72a69e4d63 100644 > --- a/accel/tcg/internal.h > +++ b/accel/tcg/internal.h > @@ -18,4 +18,6 @@ TranslationBlock *tb_gen_code(CPUState *cpu, > > void tb_flush_jmp_cache(CPUState *cpu, target_ulong addr); > > +void QEMU_NORETURN cpu_io_recompile(CPUState *cpu, uintptr_t retaddr); > + > #endif > diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h > index 3acc7c2943a..125000bcf70 100644 > --- a/include/exec/exec-all.h > +++ b/include/exec/exec-all.h > @@ -63,7 +63,6 @@ void restore_state_to_opc(CPUArchState *env, > TranslationBlock *tb, > bool cpu_restore_state(CPUState *cpu, uintptr_t searched_pc, bool will_exit); > > void QEMU_NORETURN cpu_loop_exit_noexc(CPUState *cpu); > -void QEMU_NORETURN cpu_io_recompile(CPUState *cpu, uintptr_t retaddr); > void QEMU_NORETURN cpu_loop_exit(CPUState *cpu); > void QEMU_NORETURN cpu_loop_exit_restore(CPUState *cpu, uintptr_t pc); > void QEMU_NORETURN cpu_loop_exit_atomic(CPUState *cpu, uintptr_t pc); >