On 9/2/21 6:15 PM, Philippe Mathieu-Daudé wrote:
+#ifndef CONFIG_USER_ONLY
static inline bool cpu_handle_halt(CPUState *cpu)
{
Hmm, slightly better to move the ifdef just inside here,
@@ -607,6 +608,7 @@ static inline bool cpu_handle_halt(CPUState *cpu)
and here,
return false;
}
+#endif /* !CONFIG_USER_ONLY */
static inline void cpu_handle_debug_exception(CPUState *cpu)
{
@@ -865,9 +867,11 @@ int cpu_exec(CPUState *cpu)
/* replay_interrupt may need current_cpu */
current_cpu = cpu;
+#ifndef CONFIG_USER_ONLY
if (cpu_handle_halt(cpu)) {
return EXCP_HALTED;
}
+#endif
which would eliminate this one.
r~