xserver: Branch 'master'
Matthias Hopf
mhopf at kemper.freedesktop.org
Thu Mar 15 17:56:37 EET 2007
hw/xfree86/x86emu/prim_ops.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
New commits:
diff-tree 2fe74ef339c3a4902ae8214f5a0454662895422c (from ae75019ccf1edac9e8be31b6a96293624f672ccb)
Author: Matthias Hopf <mhopf at suse.de>
Date: Thu Mar 15 16:56:01 2007 +0100
Fix calculations in x86 emulator for the long long case (Andreas Schwab).
diff --git a/hw/xfree86/x86emu/prim_ops.c b/hw/xfree86/x86emu/prim_ops.c
index 461e09e..b9e7257 100644
--- a/hw/xfree86/x86emu/prim_ops.c
+++ b/hw/xfree86/x86emu/prim_ops.c
@@ -2082,7 +2082,7 @@ Implements the IMUL instruction and side
void imul_long_direct(u32 *res_lo, u32* res_hi,u32 d, u32 s)
{
#ifdef __HAS_LONG_LONG__
- s64 res = (s32)d * (s32)s;
+ s64 res = (s64)(s32)d * (s32)s;
*res_lo = (u32)res;
*res_hi = (u32)(res >> 32);
@@ -2174,7 +2174,7 @@ Implements the MUL instruction and side
void mul_long(u32 s)
{
#ifdef __HAS_LONG_LONG__
- u64 res = (u32)M.x86.R_EAX * (u32)s;
+ u64 res = (u64)M.x86.R_EAX * s;
M.x86.R_EAX = (u32)res;
M.x86.R_EDX = (u32)(res >> 32);
More information about the xorg-commit
mailing list