[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL v2 47/60] tcg: Extend call args using the correct opcodes
From: |
Richard Henderson |
Subject: |
[PULL v2 47/60] tcg: Extend call args using the correct opcodes |
Date: |
Thu, 28 Oct 2021 21:33:16 -0700 |
Pretending that the source is i64 when it is in fact i32 is
incorrect; we have type-changing opcodes that must be used.
This bug trips up the subsequent change to the optimizer.
Fixes: 4f2331e5b67a
Reviewed-by: Luis Pires <luis.pires@eldorado.org.br>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
tcg/tcg.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tcg/tcg.c b/tcg/tcg.c
index 024a22cf39..6332cdceca 100644
--- a/tcg/tcg.c
+++ b/tcg/tcg.c
@@ -1508,11 +1508,11 @@ void tcg_gen_callN(void *func, TCGTemp *ret, int nargs,
TCGTemp **args)
if (is_32bit) {
TCGv_i64 temp = tcg_temp_new_i64();
- TCGv_i64 orig = temp_tcgv_i64(args[i]);
+ TCGv_i32 orig = temp_tcgv_i32(args[i]);
if (is_signed) {
- tcg_gen_ext32s_i64(temp, orig);
+ tcg_gen_ext_i32_i64(temp, orig);
} else {
- tcg_gen_ext32u_i64(temp, orig);
+ tcg_gen_extu_i32_i64(temp, orig);
}
args[i] = tcgv_i64_temp(temp);
}
--
2.25.1
- [PULL v2 39/60] tcg/optimize: Split out fold_to_not, (continued)
- [PULL v2 39/60] tcg/optimize: Split out fold_to_not, Richard Henderson, 2021/10/29
- [PULL v2 38/60] tcg/optimize: Add type to OptContext, Richard Henderson, 2021/10/29
- [PULL v2 40/60] tcg/optimize: Split out fold_sub_to_neg, Richard Henderson, 2021/10/29
- [PULL v2 41/60] tcg/optimize: Split out fold_xi_to_x, Richard Henderson, 2021/10/29
- [PULL v2 42/60] tcg/optimize: Split out fold_ix_to_i, Richard Henderson, 2021/10/29
- [PULL v2 43/60] tcg/optimize: Split out fold_masks, Richard Henderson, 2021/10/29
- [PULL v2 45/60] tcg/optimize: Expand fold_addsub2_i32 to 64-bit ops, Richard Henderson, 2021/10/29
- [PULL v2 48/60] tcg/optimize: Stop forcing z_mask to "garbage" for 32-bit values, Richard Henderson, 2021/10/29
- [PULL v2 60/60] softmmu: fix for "after access" watchpoints, Richard Henderson, 2021/10/29
- [PULL v2 44/60] tcg/optimize: Expand fold_mulu2_i32 to all 4-arg multiplies, Richard Henderson, 2021/10/29
- [PULL v2 47/60] tcg: Extend call args using the correct opcodes,
Richard Henderson <=
- [PULL v2 46/60] tcg/optimize: Sink commutative operand swapping into fold functions, Richard Henderson, 2021/10/29
- [PULL v2 51/60] tcg/optimize: Use fold_xi_to_x for div, Richard Henderson, 2021/10/29
- [PULL v2 52/60] tcg/optimize: Use fold_xx_to_i for rem, Richard Henderson, 2021/10/29
- [PULL v2 55/60] tcg/optimize: Propagate sign info for setcond, Richard Henderson, 2021/10/29
- [PULL v2 54/60] tcg/optimize: Propagate sign info for logical operations, Richard Henderson, 2021/10/29
- [PULL v2 58/60] softmmu: fix watchpoint processing in icount mode, Richard Henderson, 2021/10/29
- [PULL v2 50/60] tcg/optimize: Use fold_xi_to_x for mul, Richard Henderson, 2021/10/29
- [PULL v2 53/60] tcg/optimize: Optimize sign extensions, Richard Henderson, 2021/10/29
- [PULL v2 49/60] tcg/optimize: Use fold_xx_to_i for orc, Richard Henderson, 2021/10/29
- [PULL v2 57/60] tcg/optimize: Propagate sign info for shifting, Richard Henderson, 2021/10/29