qemu/target
Peter Maydell 160f3b64c5 target/arm: Add helpers for VFP register loads and stores
The current VFP code has two different idioms for
loading and storing from the VFP register file:
 1 using the gen_mov_F0_vreg() and similar functions,
   which load and store to a fixed set of TCG globals
   cpu_F0s, CPU_F0d, etc
 2 by direct calls to tcg_gen_ld_f64() and friends

We want to phase out idiom 1 (because the use of the
fixed globals is a relic of a much older version of TCG),
but idiom 2 is quite longwinded:
 tcg_gen_ld_f64(tmp, cpu_env, vfp_reg_offset(true, reg))
requires us to specify the 64-bitness twice, once in
the function name and once by passing 'true' to
vfp_reg_offset(). There's no guard against accidentally
passing the wrong flag.

Instead, let's move to a convention of accessing 64-bit
registers via the existing neon_load_reg64() and
neon_store_reg64(), and provide new neon_load_reg32()
and neon_store_reg32() for the 32-bit equivalents.

Implement the new functions and use them in the code in
translate-vfp.inc.c. We will convert the rest of the VFP
code as we do the decodetree conversion in subsequent
commits.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2019-06-13 15:14:04 +01:00
..
alpha Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
arm target/arm: Add helpers for VFP register loads and stores 2019-06-13 15:14:04 +01:00
cris Supply missing header guards 2019-06-12 13:20:21 +02:00
hppa Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
i386 Miscellaneous patches for 2019-06-11 2019-06-12 13:50:02 +01:00
lm32 Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
m68k Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
microblaze Supply missing header guards 2019-06-12 13:20:21 +02:00
mips Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
moxie Supply missing header guards 2019-06-12 13:20:21 +02:00
nios2 Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
openrisc Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
ppc ppc patch queue 2019-06-12 2019-06-12 14:43:47 +01:00
riscv Supply missing header guards 2019-06-12 13:20:21 +02:00
s390x Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
sh4 Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
sparc Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
tilegx Normalize position of header guard 2019-06-12 13:20:20 +02:00
tricore Supply missing header guards 2019-06-12 13:20:21 +02:00
unicore32 Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
xtensa Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00