Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: Notesfiles $Revision: 1.7.0.10 $; site uiucdcsb Path: utzoo!watmath!clyde!cbosgd!ihnp4!inuxc!pur-ee!uiucdcs!uiucdcsb!kenny From: kenny@uiucdcsb.CS.UIUC.EDU Newsgroups: net.lang.c Subject: Re: Re: Float Double Parameters Message-ID: <139200025@uiucdcsb> Date: Fri, 11-Apr-86 10:38:00 EST Article-I.D.: uiucdcsb.139200025 Posted: Fri Apr 11 10:38:00 1986 Date-Received: Mon, 21-Apr-86 07:57:36 EST References: <5216@alice> Lines: 30 Nf-ID: #R:alice:-521600:uiucdcsb:139200025:000:1419 Nf-From: uiucdcsb.CS.UIUC.EDU!kenny Apr 11 09:38:00 1986 /* Written 10:34 pm Apr 7, 1986 by herndon@umn-cs in uiucdcsb:net.lang.c */ As far as I know (admittedly, not far) there is no longer any good reason for the current schizophrenia about single/double precision arithmetic, other than historical precedent. Does anyone know any other good reasons, such as design faults in the VAX FPA? Robert Herndon /* End of text from uiucdcsb:net.lang.c */ No, but you have (possibly) the wrong historical precedent. On the GE 635 (and its successors), *all* floating-point arithmetic was double-precision internally. Single-precision *instructions* existed, but all they did was to pad or truncate the operand appropriately. The GE Fortran library's mathematical functions all, therefore, accepted only double-precision operands (SIN and DSIN were the same function). When BCPL was built for the 635, it borrowed the existing Fortran library and hence had to adopt the convention that all float's are promoted to double's for parameter passing. 'B' (Anyone else remember 'B'? It was a neat language [compared to what was available before 'C']) and later 'C' inherited this kludge from BCPL. Kevin Kenny University of Illinois at Urbana-Champaign UUCP: {ihnp4,pur-ee,convex}!uiucdcs!kenny CSNET: kenny@UIUC.CSNET ARPA: kenny@B.CS.UIUC.EDU (kenny@UIUC.ARPA) "Yes, understanding today's complex world is a bit like having bees live in your head, but there they are."