]> git.ipfire.org Git - thirdparty/qemu.git/commit
tcg/mips: fix add2
authorAurelien Jarno <aurelien@aurel32.net>
Fri, 31 Jul 2015 14:38:25 +0000 (16:38 +0200)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Tue, 4 Aug 2015 17:30:37 +0000 (12:30 -0500)
commite750591c8abc0f68296f1afa9f3b9e678b4a28be
treefe8bd6ab8dfe93d82ab13a10b5bbd858e45088f1
parentf9c0ae272389b3581be13fe13986d7c509995be1
tcg/mips: fix add2

The add2 code in the tcg_out_addsub2 function doesn't take into account
the case where rl == al == bl. In that case we can't compute the carry
after the addition. As it corresponds to a multiplication by 2, the
carry bit is the bit 31.

While this is a corner case, this prevents x86-64 guests to boot on a
MIPS host.

Cc: qemu-stable@nongnu.org
Reviewed-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
(cherry picked from commit c99d69694af4ed15b33e3f7c2e3ef6972c14358d)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
tcg/mips/tcg-target.c