Short: Mathffp.library FPU speedup patch 1.10b Author: Jess Sosnoski (at the below address!!!) Uploader: starblaz ptdprolog net Type: util/boot Version: 1.10beta Requires: kick 2.04+, an 020+ Architecture: m68k-amigaos Long: FFPpatch 1.10beta © 1997-1998 Jess Sosnoski DESCRIPTION: ----------- This is a program that patches some functions of the mathffp.library to use 68881/2 instructions, thus squeezing out a bit more speed. (I hope!) Speeded up FPU-using functions are SPDiv, SPMul, SPCeil, SPFloor This is also the first speedup patch I ever attempted to write! :) Works on an '040 or '060 too! But only uses FPU versions of SPDiv and SPMul. HISTORY: ------- 1.0 First Release 1.1 Now closes mathffp.library when mathtrans.lib v40 can't be opened Optimized spmul, spdiv, spabs, spneg, spflt, spfloor and squeezed a couple more clock cycles out. (spadd and spsub optimized too, but disabled cuz they were slower for some reason :( ) Removed SPFix patch...it was slower :( 1.2 Due to my rewriting of ffptest (included), I was able to more accurately test speed of calls to mathffp.library. I found out everything went faster in the first place :) Re-enabled everything. 1.3 Contacted Martin Berndt, author of fmath40x.lha, and asked about the Fieee and Tieee functions....so, he emailed me the source...and I removed the mathtrans.library requirement and put the functions directly into the patch program, making it faster :) 1.4 Longword aligned all patches. Changed spabs, spneg and spflt functions to not use fpu... they didn't have to do all that work, and were probably horribly slower before. (worst case..they're probably the same speed as the stock library now ..but, one of them can likely be inlined directly into the jumptable in some future version to save a clock cycle or two) Changed the SPFieee function to a faster one. Changed the SPFix function to something more like the original. 1.5 Inlined the SPFieee function whereever possible shaving off more clock cycles. Included Dave Jones' optimized SPTst and SPCmp functions! 32-bit aligned everything for better 040 performance. 1.6 Added checks for 040+ processors...disables SPFloor and SPCeil patches, which use instructions not available on 040+'s, Optimized SpCeil, Fieee, SPCmp/Tst, SPFix. Fixed some patching bugs. Sourcecode cleaned up a lot. 1.7 bad results. (That'll teach me to preserve the CCR!) 1.8 Inlined SPTieee function, shaving off a couple more clock cycles. 1.9 Now checks for my mathffp.library v43 replacement, and doesn't patch if installed. Fixed a bug in SPCmp that was causing problems with picticon not scaling images. Speeded up SPFix. 1.10 Replaced FPU version of SPAdd, SPSub, and SPFlt with regular 680x0 code, which was faster. Overworked SPFieee function. SPAbs, and SPNeg are the same as the standard mathffp.library. (hehhe...one of them is ANDI.B #$7F,D0 RTS) They're just in there for completeness. Replaced testprogram with Gerd Wieczorek's testprogram. AUTHOR: ------ Jess Sosnoski 651 Hillside Drive Mount Carmel, PA 17851-2463 USA starblaz@ptdprolog.net Updates will appear on my webpage before they appear in Aminet's RECENT file. http://home.ptd.net/~starblaz IRC nick: starblazr On: galaxynet (amiga channels), dalnet (#miggy1) pulsarnet (#elitecafe) Emails, gifts, money, food, cigarettes, Amiga4060T's will all be gladly accepted.