qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 01/10] target/arm: Move some TLBI insns to their own source f


From: Richard Henderson
Subject: Re: [PATCH 01/10] target/arm: Move some TLBI insns to their own source file
Date: Tue, 10 Dec 2024 12:07:39 -0600
User-agent: Mozilla Thunderbird

On 12/10/24 10:04, Peter Maydell wrote:
target/arm/helper.c is very large and unwieldy.  One subset of code
that we can pull out into its own file is the cpreg arrays and
corresponding functions for the TLBI instructions.

Because these are instructions they are only relevant for TCG and we
can make the new file only be built for CONFIG_TCG.

In this commit we move the AArch32 instructions from:
  not_v7_cp_reginfo[]
  v7_cp_reginfo[]
  v7mp_cp_reginfo[]
  v8_cp_reginfo[]
into a new file target/arm/tcg/tlb-insns.c.

A few small functions are used both by functions we haven't yet moved
across and by functions we have already moved.  We temporarily make
these global with a prototype in cpregs.h; when the move of all TLBI
insns is complete these will return to being file-local.

For CONFIG_TCG, this is just moving code around.  For a KVM only
build, these cpregs will no longer be added to the cpregs hashtable
for the CPU.  However this should not be a behaviour change, because:
  * we never try to migration sync or otherwise include
    ARM_CP_NO_RAW cpregs
  * for migration we treat the kernel's list of system registers
    as the authoritative one, so these TLBI insns were never
    in it anyway
The no-tcg stub of define_tlb_insn_regs() therefore does nothing.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>


r~



reply via email to

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