Author: aandrejevic
Date: Sun Nov 22 01:12:34 2015
New Revision: 69998
URL:
http://svn.reactos.org/svn/reactos?rev=69998&view=rev
Log:
[CRT]
Check for positive and negative infinity in exp().
Modified:
trunk/reactos/lib/sdk/crt/math/i386/exp_asm.s
Modified: trunk/reactos/lib/sdk/crt/math/i386/exp_asm.s
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/math/i386/exp_…
==============================================================================
--- trunk/reactos/lib/sdk/crt/math/i386/exp_asm.s [iso-8859-1] (original)
+++ trunk/reactos/lib/sdk/crt/math/i386/exp_asm.s [iso-8859-1] Sun Nov 22 01:12:34 2015
@@ -11,6 +11,18 @@
mov ebp, esp
fld qword ptr [ebp + 8]
+ fxam
+ fstsw ax
+ fwait
+ sahf
+ jnp .not_inf
+ jnc .not_inf
+ test ah, 2
+ jz .done
+ fstp st
+ fldz
+ jmp .done
+.not_inf:
fldl2e
fmul st, st(1)
fst st(1)
@@ -22,7 +34,7 @@
faddp st(1), st
fscale
fstp st(1)
-
+.done:
pop ebp
ret