[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 18/24] tcg/loongarch64: Enable v256 with LASX
From: |
Richard Henderson |
Subject: |
[PULL 18/24] tcg/loongarch64: Enable v256 with LASX |
Date: |
Wed, 19 Jun 2024 13:59:46 -0700 |
Reviewed-by: Song Gao <gaosong@loongson.cn>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
tcg/loongarch64/tcg-target.h | 2 +-
tcg/loongarch64/tcg-target.c.inc | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/tcg/loongarch64/tcg-target.h b/tcg/loongarch64/tcg-target.h
index 990bad1d51..58bd7d258e 100644
--- a/tcg/loongarch64/tcg-target.h
+++ b/tcg/loongarch64/tcg-target.h
@@ -173,7 +173,7 @@ typedef enum {
#define TCG_TARGET_HAS_v64 (cpuinfo & CPUINFO_LSX)
#define TCG_TARGET_HAS_v128 (cpuinfo & CPUINFO_LSX)
-#define TCG_TARGET_HAS_v256 0
+#define TCG_TARGET_HAS_v256 (cpuinfo & CPUINFO_LASX)
#define TCG_TARGET_HAS_not_vec 1
#define TCG_TARGET_HAS_neg_vec 1
diff --git a/tcg/loongarch64/tcg-target.c.inc b/tcg/loongarch64/tcg-target.c.inc
index dff966c395..1c4dc4decb 100644
--- a/tcg/loongarch64/tcg-target.c.inc
+++ b/tcg/loongarch64/tcg-target.c.inc
@@ -2487,6 +2487,9 @@ static void tcg_target_init(TCGContext *s)
if (cpuinfo & CPUINFO_LSX) {
tcg_target_available_regs[TCG_TYPE_V64] = ALL_VECTOR_REGS;
tcg_target_available_regs[TCG_TYPE_V128] = ALL_VECTOR_REGS;
+ if (cpuinfo & CPUINFO_LASX) {
+ tcg_target_available_regs[TCG_TYPE_V256] = ALL_VECTOR_REGS;
+ }
tcg_regset_reset_reg(tcg_target_call_clobber_regs, TCG_REG_V24);
tcg_regset_reset_reg(tcg_target_call_clobber_regs, TCG_REG_V25);
tcg_regset_reset_reg(tcg_target_call_clobber_regs, TCG_REG_V26);
--
2.34.1
- [PULL 12/24] tcg/loongarch64: Support LASX in tcg_out_addsub_vec, (continued)
- [PULL 12/24] tcg/loongarch64: Support LASX in tcg_out_addsub_vec, Richard Henderson, 2024/06/19
- [PULL 06/24] tcg/loongarch64: Simplify tcg_out_dup_vec, Richard Henderson, 2024/06/19
- [PULL 07/24] tcg/loongarch64: Support LASX in tcg_out_dup_vec, Richard Henderson, 2024/06/19
- [PULL 11/24] tcg/loongarch64: Simplify tcg_out_addsub_vec, Richard Henderson, 2024/06/19
- [PULL 13/24] tcg/loongarch64: Split out vdvjvk in tcg_out_vec_op, Richard Henderson, 2024/06/19
- [PULL 14/24] tcg/loongarch64: Support LASX in tcg_out_{mov,ld,st}, Richard Henderson, 2024/06/19
- [PULL 17/24] tcg/loongarch64: Support LASX in tcg_out_vec_op, Richard Henderson, 2024/06/19
- [PULL 21/24] accel/tcg: Fix typo causing tb->page_addr[1] to not be recorded, Richard Henderson, 2024/06/19
- [PULL 15/24] tcg/loongarch64: Remove temp_vec from tcg_out_vec_op, Richard Henderson, 2024/06/19
- [PULL 16/24] tcg/loongarch64: Split out vdvjukN in tcg_out_vec_op, Richard Henderson, 2024/06/19
- [PULL 18/24] tcg/loongarch64: Enable v256 with LASX,
Richard Henderson <=
- [PULL 22/24] linux-user: Make TARGET_NR_setgroups affect only the current thread, Richard Henderson, 2024/06/19
- [PULL 19/24] util/bufferiszero: Split out host include files, Richard Henderson, 2024/06/19
- [PULL 24/24] tcg/loongarch64: Fix tcg_out_movi vs some pcrel pointers, Richard Henderson, 2024/06/19
- [PULL 20/24] util/bufferiszero: Add loongarch64 vector acceleration, Richard Henderson, 2024/06/19
- [PULL 23/24] target/sparc: use signed denominator in sdiv helper, Richard Henderson, 2024/06/19
- Re: [PULL 00/24] tcg patch queue, Richard Henderson, 2024/06/20