From: George H. <geo...@us...> - 2006-01-28 10:28:44
|
Update of /cvsroot/win32forth/win32forth/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19199/win32forth/src Modified Files: FLOAT.F Log Message: gah: More Dexing (still work in progress) Index: FLOAT.F =================================================================== RCS file: /cvsroot/win32forth/win32forth/src/FLOAT.F,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** FLOAT.F 24 Jan 2006 09:22:39 -0000 1.26 --- FLOAT.F 28 Jan 2006 10:28:31 -0000 1.27 *************** *** 945,965 **** code F+ ( fs: r1 r2 -- r3 ) \ ANSI Floating fstack-check_2 - 2>FPU faddp st(1), st FPU> - float; ! code F- ( fs: r1 r2 -- r3 ) \ ? overflow errors fstack-check_2 2>FPU - \ fxch fsubrp st(1), st FPU> float; ! code F* ( fs: r1 r2 -- r3 ) \ ? overflow errors fstack-check_2 2>FPU --- 945,965 ---- code F+ ( fs: r1 r2 -- r3 ) \ ANSI Floating + \ *G Add r1 to r2. fstack-check_2 2>FPU faddp st(1), st FPU> float; ! code F- ( fs: r1 r2 -- r3 ) \ ANSI Floating ! \ *G Subtract r2 from r1. fstack-check_2 2>FPU fsubrp st(1), st FPU> float; ! code F* ( fs: r1 r2 -- r3 ) \ ANSI Floating ! \ *G Multiply r1 by r2. fstack-check_2 2>FPU *************** *** 968,972 **** float; ! code F/ ( fs: r1 r2 -- r3 ) \ ANSI Floating fstack-check_2 2>FPU --- 968,973 ---- float; ! code F/ ( fs: r1 r2 -- r3 ) \ ANSI Floating ! \ *G Divide r1 by r2. fstack-check_2 2>FPU *************** *** 976,988 **** float; ! code FATAN2 ( fs: r1 r2 -- r3 ) \ OK for valid args ! fstack-check_2 ! 2>FPU ! fxch ! fpatan ! FPU> ! float; ! ! code FNEGATE ( fs: r1 -- r2 ) fstack-check_1 >FPU --- 977,982 ---- float; ! code FNEGATE ( fs: r1 -- r2 ) \ ANSI Floating ! \ *G Reverse the sign of r1. fstack-check_1 >FPU *************** *** 1121,1124 **** --- 1115,1120 ---- external + \ *N Trigonometric functions + : FSIN ( f: r1 -- r2 ) \ ? error if x > 2**63 ? >a2**63_frem2pi (fsin) ; *************** *** 1133,1136 **** --- 1129,1181 ---- fsincos f/ ; + \ *N Inverse Trigonometric functions + + code FASIN ( fs: r1 -- r2 ) \ result for |x| > 1 is NAN + fstack-check_1 + >FPU + fld st(0) + fld st(0) + fmulp st(1), st(0) + fld1 + fsubpr st(1), st + fabs + fsqrt + fpatan + FPU> + float; + + code FACOS ( fs: r1 -- r2 ) \ result for |x| > 1 is NAN + fstack-check_1 + >FPU + fld st(0) + fld st(0) + fmulp st(1), st(0) + fld1 + fsubpr st(1), st + fsqrt + fabs + fxch st(1) + fpatan + FPU> + float; + + code FATAN ( fs: r1 -- r2 ) \ should be OK for legal args + fstack-check_1 + >FPU + fld1 + fpatan + FPU> + float; + + code FATAN2 ( fs: r1 r2 -- r3 ) \ ANSI Floating ext + \ *G r3 is the radian angle whose tangent is r1/r2. If r1 and r2 are both zero then r3 + \ ** is zero. + fstack-check_2 + 2>FPU + fxch + fpatan + FPU> + float; + code FLNP1 ( fs: r1 -- r2 ) \ ? error for x <= -1 fstack-check_1 *************** *** 1262,1308 **** THEN ; - code FATAN ( fs: r1 -- r2 ) \ should be OK for legal args - fstack-check_1 - - >FPU - fld1 - fpatan - FPU> - - float; - - code FACOS ( fs: r1 -- r2 ) \ result for |x| > 1 is NAN - fstack-check_1 - - >FPU - fld st(0) - fld st(0) - fmulp st(1), st(0) - fld1 - fsubpr st(1), st - fsqrt - fabs - fxch st(1) - fpatan - FPU> - - float; - - code FASIN ( fs: r1 -- r2 ) \ result for |x| > 1 is NAN - fstack-check_1 - - >FPU - fld st(0) - fld st(0) - fmulp st(1), st(0) - fld1 - fsubpr st(1), st - fabs - fsqrt - fpatan - FPU> - - float; - internal --- 1307,1310 ---- *************** *** 1891,1895 **** \ *P The following words are for formatting floating point numbers as counted strings in ! \ ** the buffer whose address supplied so they can be used for purposes other than printing \ ** the numbers to the console. The string is not null terminated. --- 1893,1897 ---- \ *P The following words are for formatting floating point numbers as counted strings in ! \ ** the buffer whose address is supplied so they can be used for purposes other than printing \ ** the numbers to the console. The string is not null terminated. |