From: malc Date: Tue, 15 Dec 2009 16:44:20 +0000 (+0300) Subject: tcg/ppc64: Fix loading of 32bit constants X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=591d6f1dfdb60ab0a4cc487cd5781fa799dcac4b;p=qemu.git tcg/ppc64: Fix loading of 32bit constants Signed-off-by: malc --- diff --git a/tcg/ppc64/tcg-target.c b/tcg/ppc64/tcg-target.c index 0c11917c15..803db481fd 100644 --- a/tcg/ppc64/tcg-target.c +++ b/tcg/ppc64/tcg-target.c @@ -463,8 +463,9 @@ static void tcg_out_movi (TCGContext *s, TCGType type, int ret, tcg_target_long arg) { int32_t arg32 = arg; + arg = type == TCG_TYPE_I32 ? arg & 0xffffffff : arg; - if (type == TCG_TYPE_I32 || arg == arg32) { + if (arg == arg32) { tcg_out_movi32 (s, ret, arg32); } else {