[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [PATCH 17/70] target/hexagon/idef-parser: Use gen_tmp for gen_pred_a
From: |
Taylor Simpson |
Subject: |
RE: [PATCH 17/70] target/hexagon/idef-parser: Use gen_tmp for gen_pred_assign |
Date: |
Mon, 27 Feb 2023 21:55:33 +0000 |
> -----Original Message-----
> From: Richard Henderson <richard.henderson@linaro.org>
> Sent: Sunday, February 26, 2023 10:42 PM
> To: qemu-devel@nongnu.org
> Cc: qemu-arm@nongnu.org; qemu-ppc@nongnu.org; qemu-
> riscv@nongnu.org; qemu-s390x@nongnu.org; jcmvbkbc@gmail.com;
> kbastian@mail.uni-paderborn.de; ysato@users.sourceforge.jp;
> gaosong@loongson.cn; jiaxun.yang@flygoat.com; Taylor Simpson
> <tsimpson@quicinc.com>; ale@rev.ng; mrolnik@gmail.com;
> edgar.iglesias@gmail.com
> Subject: [PATCH 17/70] target/hexagon/idef-parser: Use gen_tmp for
> gen_pred_assign
>
> The allocation is immediately followed by tcg_gen_mov_i32, so the initial
> assignment of zero is discarded.
>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
> target/hexagon/idef-parser/parser-helpers.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/target/hexagon/idef-parser/parser-helpers.c
> b/target/hexagon/idef-parser/parser-helpers.c
> index be979dac86..760e499149 100644
> --- a/target/hexagon/idef-parser/parser-helpers.c
> +++ b/target/hexagon/idef-parser/parser-helpers.c
> @@ -1743,7 +1743,7 @@ void gen_pred_assign(Context *c, YYLTYPE *locp,
> HexValue *left_pred,
> "Predicate assign not allowed in ternary!");
> /* Extract predicate TCGv */
> if (is_direct) {
> - *left_pred = gen_tmp_value(c, locp, "0", 32, UNSIGNED);
> + *left_pred = gen_tmp(c, locp, 32, UNSIGNED);
> }
> /* Extract first 8 bits, and store new predicate value */
> OUT(c, locp, "tcg_gen_mov_i32(", left_pred, ", ", &r, ");\n");
Let's combine this OUT statement with the next one
- OUT(c, locp, "tcg_gen_mov_i32(", left_pred, ", ", &r, ");\n");
- OUT(c, locp, "tcg_gen_andi_i32(", left_pred, ", ", left_pred,
+ OUT(c, locp, "tcg_gen_andi_i32(", left_pred, ", ", &r,
", 0xff);\n");
Otherwise,
Reviewed-by: Taylor Simpson <tsimpson@quicinc.com>
- [PATCH 10/70] target/arm: Avoid tcg_const_ptr in handle_vec_simd_sqshrn, (continued)
- [PATCH 10/70] target/arm: Avoid tcg_const_ptr in handle_vec_simd_sqshrn, Richard Henderson, 2023/02/27
- [PATCH 11/70] target/arm: Avoid tcg_const_ptr in handle_rev, Richard Henderson, 2023/02/27
- [PATCH 12/70] target/avr: Avoid use of tcg_const_i32 in SBIC, SBIS, Richard Henderson, 2023/02/27
- [PATCH 13/70] target/avr: Avoid use of tcg_const_i32 throughout, Richard Henderson, 2023/02/27
- [PATCH 14/70] target/cris: Avoid use of tcg_const_i32 throughout, Richard Henderson, 2023/02/27
- [PATCH 15/70] target/hexagon: Use tcg_constant_* for gen_constant_from_imm, Richard Henderson, 2023/02/27
- [PATCH 16/70] target/hexagon/idef-parser: Use gen_tmp for LPCFG, Richard Henderson, 2023/02/27
- [PATCH 17/70] target/hexagon/idef-parser: Use gen_tmp for gen_pred_assign, Richard Henderson, 2023/02/27
- RE: [PATCH 17/70] target/hexagon/idef-parser: Use gen_tmp for gen_pred_assign,
Taylor Simpson <=
- [PATCH 19/70] target/hexagon/idef-parser: Use gen_constant for gen_extend_tcg_width_op, Richard Henderson, 2023/02/27
- [PATCH 18/70] target/hexagon/idef-parser: Use gen_tmp for gen_rvalue_pred, Richard Henderson, 2023/02/27
- [PATCH 20/70] target/hppa: Avoid tcg_const_i64 in trans_fid_f, Richard Henderson, 2023/02/27
- [PATCH 21/70] target/hppa: Avoid use of tcg_const_i32 throughout, Richard Henderson, 2023/02/27
- [PATCH 24/70] target/m68k: Reject immediate as destination in gen_ea_mode, Richard Henderson, 2023/02/27
- [PATCH 22/70] target/i386: Simplify POPF, Richard Henderson, 2023/02/27