Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site ima.UUCP Path: utzoo!watmath!clyde!burl!ulysses!bellcore!decvax!ima!johnl From: johnl@ima.UUCP (John R. Levine) Newsgroups: net.arch Subject: Re: RISC cache vs CISC u-code Message-ID: <146@ima.UUCP> Date: Sun, 9-Mar-86 17:28:34 EST Article-I.D.: ima.146 Posted: Sun Mar 9 17:28:34 1986 Date-Received: Tue, 11-Mar-86 01:40:44 EST References: <136@pyramid.UUCP> <570@imag.UUCP> <4521@think.ARPA> <765@harvard.UUCP> Reply-To: johnl@ima.UUCP (John R. Levine) Organization: Javelin Software Corp. Lines: 30 Summary: who needs a fancy subroutine linkage? In article <765@harvard.UUCP> reiter@harvard.UUCP (Ehud reiter) writes: >One last point - the RT does NOT have a fancy subroutine call mechanism (like >Berkeley's RISC). So, even if it were true that an RT could execute a MULTIPLY >routine out of memory as fast as a CISC machine could execute it out of >microcode, the RISC multiply is much more expensive because of the subroutine >call overhead. Huh? Not true at all (and I should know, I wrote the multiply routine for the AIX C compiler.) There are two points. One is that the multiply routine is what has been called "millicode" which does not go through a full function linkage. In the AIX compiler, you just put the two numbers to be multiplied in two registers and jump; the routine doesn't save anything so there is negligible linkage overhead. The other point doesn't apply directly to the RT but is generally important, and it is that with decent compilers you don't need the sliding register window hack. Neither the MIPS chip nor the 801 had multiple register sets, in both case because the compiler technology made them unnecessary. Even in the AIX compiler, which is a straightforward version of PCC, careful choice of argument and scratch registers keeps the number of registers saved per call to a minimum. I saw some of the code generated by the PL.8 compiler, and it was pretty spectacular. Register windows would have bought practically nothing. -- John Levine, Javelin Software, Cambridge MA 617-494-1400 { decvax | harvard | think | ihnp4 | cbosgd }!ima!johnl, Levine@YALE.ARPA The opinions above are solely those of a 12 year old hacker who has broken into my account, and not those of my employer or any other organization.