mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-10 02:54:58 -06:00
target/ppc: introduce get_avr64() and set_avr64() helpers for VMX register access
These helpers allow us to move AVR register values to/from the specified TCGv_i64 argument. To prevent VMX helpers accessing the cpu_avr{l,h} arrays directly, add extra TCG temporaries as required. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
1a404c91bd
commit
c4a18dbf52
2 changed files with 123 additions and 32 deletions
|
@ -6709,6 +6709,16 @@ static inline void set_fpr(int regno, TCGv_i64 src)
|
|||
tcg_gen_mov_i64(cpu_fpr[regno], src);
|
||||
}
|
||||
|
||||
static inline void get_avr64(TCGv_i64 dst, int regno, bool high)
|
||||
{
|
||||
tcg_gen_mov_i64(dst, (high ? cpu_avrh : cpu_avrl)[regno]);
|
||||
}
|
||||
|
||||
static inline void set_avr64(int regno, TCGv_i64 src, bool high)
|
||||
{
|
||||
tcg_gen_mov_i64((high ? cpu_avrh : cpu_avrl)[regno], src);
|
||||
}
|
||||
|
||||
#include "translate/fp-impl.inc.c"
|
||||
|
||||
#include "translate/vmx-impl.inc.c"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue