target/ppc: Move get/set_avr64 functions to vmx-impl.c.inc.
authorChinmay Rath <rathc@linux.ibm.com>
Tue, 9 Jul 2024 11:43:39 +0000 (17:13 +0530)
committerNicholas Piggin <npiggin@gmail.com>
Thu, 25 Jul 2024 23:51:33 +0000 (09:51 +1000)
Those functions are used to ld/st data to and from Altivec registers,
in 64 bits chunks, and are only used in vmx-impl.c.inc file,
hence the clean-up movement.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Chinmay Rath <rathc@linux.ibm.com>
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
target/ppc/translate.c
target/ppc/translate/vmx-impl.c.inc

index 46aabce82bc4bee097150b66f8e5bff4eda3b7d8..71513ba9646b5f3b4eb6c3097e6b7022e0bf8d90 100644 (file)
@@ -5558,16 +5558,6 @@ static inline void set_fpr(int regno, TCGv_i64 src)
     tcg_gen_st_i64(tcg_constant_i64(0), tcg_env, vsr64_offset(regno, false));
 }
 
-static inline void get_avr64(TCGv_i64 dst, int regno, bool high)
-{
-    tcg_gen_ld_i64(dst, tcg_env, avr64_offset(regno, high));
-}
-
-static inline void set_avr64(int regno, TCGv_i64 src, bool high)
-{
-    tcg_gen_st_i64(src, tcg_env, avr64_offset(regno, high));
-}
-
 /*
  * Helpers for decodetree used by !function for decoding arguments.
  */
index 152bcde0e3ccad5e885edf6e2a4655a30fba5d67..a182d2cf81daa4affe565bd35863fcc7d66a9a4f 100644 (file)
@@ -14,6 +14,16 @@ static inline TCGv_ptr gen_avr_ptr(int reg)
     return r;
 }
 
+static inline void get_avr64(TCGv_i64 dst, int regno, bool high)
+{
+    tcg_gen_ld_i64(dst, tcg_env, avr64_offset(regno, high));
+}
+
+static inline void set_avr64(int regno, TCGv_i64 src, bool high)
+{
+    tcg_gen_st_i64(src, tcg_env, avr64_offset(regno, high));
+}
+
 static bool trans_LVX(DisasContext *ctx, arg_X *a)
 {
     TCGv EA;