mirror of
https://git.h3cjp.net/H3cJP/citra.git
synced 2024-11-24 21:42:49 +00:00
Merge pull request #290 from lioncash/vsub
armemu: Backport some VFP fixes from 3dmoo.
This commit is contained in:
commit
ec9ac2f51a
|
@ -614,7 +614,7 @@ static u32 vfp_single_ftoui(ARMul_State* state, int sd, int unused, s32 m, u32 f
|
|||
exceptions |= FPSCR_IDC;
|
||||
|
||||
if (tm & VFP_NAN)
|
||||
vsm.sign = 0;
|
||||
vsm.sign = 1;
|
||||
|
||||
if (vsm.exponent >= 127 + 32) {
|
||||
d = vsm.sign ? 0 : 0xffffffff;
|
||||
|
@ -1148,7 +1148,10 @@ static u32 vfp_single_fsub(ARMul_State* state, int sd, int sn, s32 m, u32 fpscr)
|
|||
/*
|
||||
* Subtraction is addition with one sign inverted.
|
||||
*/
|
||||
return vfp_single_fadd(state, sd, sn, vfp_single_packed_negate(m), fpscr);
|
||||
if (m != 0x7FC00000) // Only negate if m isn't NaN.
|
||||
m = vfp_single_packed_negate(m);
|
||||
|
||||
return vfp_single_fadd(state, sd, sn, m, fpscr);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in a new issue