diff options
author | Richard Henderson <richard.henderson@linaro.org> | 2024-05-27 19:18:15 +0000 |
---|---|---|
committer | Richard Henderson <richard.henderson@linaro.org> | 2024-06-19 10:55:12 -0700 |
commit | 75b5ffdd0d026d77d23e59c18c56803d8e7e0e01 (patch) | |
tree | 0084d5934ce69874dd5deaa8d2bc68596af4a403 /tcg | |
parent | 15750faa8ecd070cbc01bbd22db8c7a2b7e410e5 (diff) |
tcg/loongarch64: Use tcg_out_dup_vec in tcg_out_dupi_vec
Reviewed-by: Song Gao <gaosong@loongson.cn>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'tcg')
-rw-r--r-- | tcg/loongarch64/tcg-target.c.inc | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/tcg/loongarch64/tcg-target.c.inc b/tcg/loongarch64/tcg-target.c.inc index 1e721b8b20..9a8f67cf3e 100644 --- a/tcg/loongarch64/tcg-target.c.inc +++ b/tcg/loongarch64/tcg-target.c.inc @@ -1749,24 +1749,8 @@ static void tcg_out_dupi_vec(TCGContext *s, TCGType type, unsigned vece, /* TODO: vldi patterns when imm 12 is set */ - /* Fallback to vreplgr2vr */ tcg_out_movi(s, TCG_TYPE_I64, TCG_REG_TMP0, value); - switch (vece) { - case MO_8: - tcg_out_opc_vreplgr2vr_b(s, rd, TCG_REG_TMP0); - break; - case MO_16: - tcg_out_opc_vreplgr2vr_h(s, rd, TCG_REG_TMP0); - break; - case MO_32: - tcg_out_opc_vreplgr2vr_w(s, rd, TCG_REG_TMP0); - break; - case MO_64: - tcg_out_opc_vreplgr2vr_d(s, rd, TCG_REG_TMP0); - break; - default: - g_assert_not_reached(); - } + tcg_out_dup_vec(s, type, vece, rd, TCG_REG_TMP0); } static void tcg_out_addsub_vec(TCGContext *s, unsigned vece, const TCGArg a0, |