The libgloss m68k-semi.txt spec says that bkpt #0 may be used when the halt insn is not available. While halt is available for 68060, continue to support bkpt #0 for all m68k processors.
Signed-off-by: Richard Henderson <richard.hender...@linaro.org> --- target/m68k/translate.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index b7adc8f53d..51c546f26f 100644 --- a/target/m68k/translate.c +++ b/target/m68k/translate.c @@ -2775,6 +2775,15 @@ DISAS_INSN(swap) DISAS_INSN(bkpt) { +#ifndef CONFIG_USER_ONLY + /* The non-ColdFire semihosting insn is bkpt #0. */ + if (!m68k_feature(s->env, M68K_FEATURE_CF_ISA_A) + && !IS_USER(s) + && (insn & 7) == 0 + && maybe_semihosting(s)) { + return; + } +#endif gen_exception(s, s->base.pc_next, EXCP_DEBUG); } -- 2.34.1