qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v14 24/34] target/arm: [tcg] Port to translate_i


From: Emilio G. Cota
Subject: Re: [Qemu-devel] [PATCH v14 24/34] target/arm: [tcg] Port to translate_insn
Date: Fri, 21 Jul 2017 19:20:58 -0400
User-agent: Mutt/1.5.24 (2015-08-30)

On Fri, Jul 14, 2017 at 23:42:33 -1000, Richard Henderson wrote:
> From: Lluís Vilanova <address@hidden>
> 
> Incrementally paves the way towards using the generic instruction translation
> loop.
> 
> Signed-off-by: Lluís Vilanova <address@hidden>
> Message-Id: <address@hidden>
> [rth: Adjust for translate_insn interface change.]
> Signed-off-by: Richard Henderson <address@hidden>
(snip)
> --- a/target/arm/translate.c
> +++ b/target/arm/translate.c
> @@ -11842,6 +11842,8 @@ static int arm_tr_init_disas_context(DisasContextBase 
> *dcbase,
>      dc->is_ldex = false;
>      dc->ss_same_el = false; /* Can't be true since EL_d must be AArch64 */
>  
> +    dc->next_page_start =
> +        (dc->base.pc_first & TARGET_PAGE_MASK) + TARGET_PAGE_SIZE;
>  
>      cpu_F0s = tcg_temp_new_i32();
>      cpu_F1s = tcg_temp_new_i32();
> @@ -11935,14 +11937,93 @@ static bool 
> arm_tr_breakpoint_check(DisasContextBase *dcbase, CPUState *cpu,
>      return true;
>  }
>  
> +static void arm_tr_translate_insn(DisasContextBase *dcbase, CPUState *cpu)
> +{
> +    DisasContext *dc = container_of(dcbase, DisasContext, base);
> +    CPUARMState *env = cpu->env_ptr;
> +
> +#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->base.is_jmp = DISAS_NORETURN;
> +            return;
> +        }
> +#endif

Nit: Indent this properly here to avoid the indent fix in patch 33.

                E.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]