On 06/25/2017 03:08 AM, Lluís Vilanova wrote:
+static void arm_trblock_insn_start(DisasContextBase *db, CPUState *cpu) +{ + DisasContext *dc = container_of(db, DisasContext, base); + + dc->insn_start_idx = tcg_op_buf_count(); + tcg_gen_insn_start(dc->pc, + (dc->condexec_cond << 4) | (dc->condexec_mask >> 1), + 0); + +#ifdef CONFIG_USER_ONLY + /* Intercept jump to the magic kernel page. */ + if (dc->pc >= 0xffff0000) { + /* We always get here via a jump, so know we are not in a + conditional execution block. */ + gen_exception_internal(EXCP_KERNEL_TRAP); + dc->is_jmp = DJ_EXC; + } +#endif +}
I think this DJ_EXC block is better placed at the start of disas_insn. It is, however, the answer to one of my questions re patch 4/26. r~