Commit 86c4a9f5131414143b2ee82acb65a74de3baa8f5

Authored by j_mayer
1 parent 273af660

Fix two PowerPC FPU emulation bugs (thanks to Aurelien Jarno)


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3487 c046a42c-6fe2-441c-8c8c-71466251a162
Showing 1 changed file with 2 additions and 2 deletions
target-ppc/op_helper.c
@@ -522,7 +522,7 @@ static always_inline int isinfinity (float64 f) @@ -522,7 +522,7 @@ static always_inline int isinfinity (float64 f)
522 522
523 u.f = f; 523 u.f = f;
524 524
525 - return ((u.u >> 52) & 0x3FF) == 0x3FF && 525 + return ((u.u >> 52) & 0x7FF) == 0x7FF &&
526 (u.u & 0x000FFFFFFFFFFFFFULL) == 0; 526 (u.u & 0x000FFFFFFFFFFFFFULL) == 0;
527 } 527 }
528 528
@@ -681,7 +681,7 @@ static always_inline void float_zero_divide_excp (void) @@ -681,7 +681,7 @@ static always_inline void float_zero_divide_excp (void)
681 u0.f = FT0; 681 u0.f = FT0;
682 u1.f = FT1; 682 u1.f = FT1;
683 u0.u = ((u0.u ^ u1.u) & 0x8000000000000000ULL); 683 u0.u = ((u0.u ^ u1.u) & 0x8000000000000000ULL);
684 - u0.u |= 0x3FFULL << 52; 684 + u0.u |= 0x7FFULL << 52;
685 FT0 = u0.f; 685 FT0 = u0.f;
686 } 686 }
687 } 687 }