Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site mplvax.UUCP Path: utzoo!watmath!clyde!bonnie!akgua!sdcsvax!sdcc3!mplvax!cdl From: cdl@mplvax.UUCP (Carl Lowenstein) Newsgroups: net.micro,net.micro.68k,net.micro.16k Subject: Re: Floating Point Comparisons Message-ID: <178@mplvax.UUCP> Date: Fri, 5-Apr-85 13:06:25 EST Article-I.D.: mplvax.178 Posted: Fri Apr 5 13:06:25 1985 Date-Received: Sun, 7-Apr-85 04:31:34 EST References: <133@cfa.UUCP> <6370@boring.UUCP> Reply-To: cdl@mplvax.UUCP (Carl Lowenstein) Distribution: net Organization: Marine Physical Laborator of SIO at UCSD Lines: 25 Xref: watmath net.micro:9950 net.micro.68k:710 net.micro.16k:314 Summary: In article <6370@boring.UUCP> jack@boring.UUCP (Jack Jansen) writes: > >In article <133@cfa.UUCP> ward@cfa.UUCP (Steve Ward) writes: >> Microprocessor FADD FSUB FMUL FDIV DADD DSUB DMUL DDIV >>NS32016/NS32081 10 MHZ 7.40 7.40 4.80 8.90 7.40 7.40 6.20 11.90 >> >Is this true? It *does* sound funny to me that additions and >subtractions take longer than multiplies.... > Jack Jansen, {decvax|philabs|seismo}!mcvax!jack If you think about it, floating-point addition and subtraction are much more difficult than multiplication. Multiplication involves only extraction and addition of the exponents, and multiplication of the fractions, with about a 25% probability of a single-bit renormalization. Addition requires the same extraction of exponent and fraction, followed by a variable shift to align binary points, the actual addition of the fractions, and then possibly a lot of renormalization, since the sum might overflow by one bit position, or underflow a lot due to cancellation between positive and negative operands. All this shifting for normalizing takes time. -- carl lowenstein marine physical lab u.c. san diego {ihnp4|decvax|akgua|dcdwest|ucbvax} !sdcsvax!mplvax!cdl