qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] 答复: Re: [PATCH] tcg/mips: Bugfix for crash when runningpro


From: jiang.biao2
Subject: [Qemu-devel] 答复: Re: [PATCH] tcg/mips: Bugfix for crash when runningprogram with qemu-i386.
Date: Fri, 7 Jul 2017 12:39:37 +0800 (CST)

>



> This is wrong, because you're not allowed to modify the input operands.
> 
> Try this, just a few lines lower in the function:
> 
> -        tcg_out_movi(s, TCG_TYPE_PTR, base, guest_base)
> -        tcg_out_opc_reg(s, ALIAS_PADD, base, base, addr_regl)
> +        tcg_out_movi(s, TCG_TYPE_PTR, TCG_TMP0, guest_base)
> +        tcg_out_opc_reg(s, ALIAS_PADD, base, TCG_TMP0, addr_regl)
> 
> and you'll need the same change within tcg_out_qemu_st.
> 
> Better would be to reserve a register for the guest_base, like we do for ppc. 
> See all of the uses of TCG_GUEST_BASE_REG in tcg/ppc/tcg-target.inc.c.
Thanks a lot for the reviewing, I'll check on these.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]