qemu-e2k/tcg/riscv
Richard Henderson 2e3a933abb tcg/riscv: Fix base register for user-only qemu_ld/st
When guest_base != 0, we were not coordinating the usage of
TCG_REG_TMP0 as base properly, leading to a previous zero-extend
of the input address being discarded.

Shuffle the alignment check to the front, because that does not
depend on the zero-extend, and it keeps the register usage clear.
Set base after each step of the address arithmetic instead of before.

Return the base register used from tcg_out_tlb_load, so as to
keep that register choice localized to that function.

Reported-by: LIU Zhiwei <zhiwei_liu@linux.alibaba.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: LIU Zhiwei <zhiwei_liu@linux.alibaba.com>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-Id: <20221023233337.2846860-1-richard.henderson@linaro.org>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
2023-01-06 10:42:55 +10:00
..
tcg-target-con-set.h tcg/riscv: Split out constraint sets to tcg-target-con-set.h 2021-02-02 12:12:43 -10:00
tcg-target-con-str.h tcg/riscv: Split out target constraints to tcg-target-con-str.h 2021-02-02 12:12:31 -10:00
tcg-target.c.inc tcg/riscv: Fix base register for user-only qemu_ld/st 2023-01-06 10:42:55 +10:00
tcg-target.h tcg/riscv: Support raising sigbus for user-only 2022-02-09 08:55:02 +11:00