[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v3 06/16] tcg/mips: Unify TCG_GUEST_BASE_REG tests
From: |
Richard Henderson |
Subject: |
[PATCH v3 06/16] tcg/mips: Unify TCG_GUEST_BASE_REG tests |
Date: |
Wed, 18 Aug 2021 10:19:21 -1000 |
In tcg_out_qemu_ld/st, we already check for guest_base matching int16_t.
Mirror that when setting up TCG_GUEST_BASE_REG in the prologue.
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
tcg/mips/tcg-target.c.inc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tcg/mips/tcg-target.c.inc b/tcg/mips/tcg-target.c.inc
index b3a2cc88ab..4019c22f3c 100644
--- a/tcg/mips/tcg-target.c.inc
+++ b/tcg/mips/tcg-target.c.inc
@@ -2671,7 +2671,7 @@ static void tcg_target_qemu_prologue(TCGContext *s)
}
#ifndef CONFIG_SOFTMMU
- if (guest_base) {
+ if (guest_base != (int16_t)guest_base) {
tcg_out_movi(s, TCG_TYPE_PTR, TCG_GUEST_BASE_REG, guest_base);
tcg_regset_set_reg(s->reserved_regs, TCG_GUEST_BASE_REG);
}
--
2.25.1
- [PATCH v3 00/16] tcg/mips: Unaligned access and other cleanup, Richard Henderson, 2021/08/18
- [PATCH v3 01/16] tcg/mips: Support unaligned access for user-only, Richard Henderson, 2021/08/18
- [PATCH v3 02/16] tcg/mips: Support unaligned access for softmmu, Richard Henderson, 2021/08/18
- [PATCH v3 06/16] tcg/mips: Unify TCG_GUEST_BASE_REG tests,
Richard Henderson <=
- [PATCH v3 08/16] tcg/mips: Unset TCG_TARGET_HAS_direct_jump, Richard Henderson, 2021/08/18
- [PATCH v3 04/16] tcg/mips: Move TCG_AREG0 to S8, Richard Henderson, 2021/08/18
- [PATCH v3 07/16] tcg/mips: Allow JAL to be out of range in tcg_out_bswap_subr, Richard Henderson, 2021/08/18
- [PATCH v3 05/16] tcg/mips: Move TCG_GUEST_BASE_REG to S7, Richard Henderson, 2021/08/18
- [PATCH v3 11/16] tcg/mips: Split out tcg_out_movi_one, Richard Henderson, 2021/08/18
- [PATCH v3 03/16] tcg/mips: Drop inline markers, Richard Henderson, 2021/08/18