mirror of
https://github.com/mii443/qemu.git
synced 2025-08-22 15:15:46 +00:00
tcg/i386: Set P_REXW in tcg_out_addi_ptr
The REXW bit must be set to produce a 64-bit pointer result; the bit is disabled in 32-bit mode, so we can do this unconditionally. Fixes:7d9e1ee424
("tcg/i386: Adjust assert in tcg_out_addi_ptr") Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1592 Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1642 Signed-off-by: Richard Henderson <richard.henderson@linaro.org> (cherry picked from commit988998503b
) Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
committed by
Michael Tokarev
parent
dbdbd71acf
commit
b2bdfb711a
@ -1083,7 +1083,7 @@ static void tcg_out_addi_ptr(TCGContext *s, TCGReg rd, TCGReg rs,
|
||||
{
|
||||
/* This function is only used for passing structs by reference. */
|
||||
tcg_debug_assert(imm == (int32_t)imm);
|
||||
tcg_out_modrm_offset(s, OPC_LEA, rd, rs, imm);
|
||||
tcg_out_modrm_offset(s, OPC_LEA | P_REXW, rd, rs, imm);
|
||||
}
|
||||
|
||||
static inline void tcg_out_pushi(TCGContext *s, tcg_target_long val)
|
||||
|
Reference in New Issue
Block a user