Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!cbatt!ucbvax!sdcsvax!celerity!jjw From: jjw@celerity.UUCP Newsgroups: comp.lang.c Subject: Re: Available No. of Registers Message-ID: <805@celerity.UUCP> Date: Mon, 26-Jan-87 11:41:37 EST Article-I.D.: celerity.805 Posted: Mon Jan 26 11:41:37 1987 Date-Received: Sat, 7-Feb-87 11:13:13 EST References: <3950004@nucsrl.UUCP> <83@ucdavis.UUCP> <2250@jade.BERKELEY.EDU> Reply-To: jjw@celerity.UUCP (Jim (JJ) Whelan) Organization: Celerity Computing, San Diego, Ca. Lines: 16 In article <2250@jade.BERKELEY.EDU> mwm@eris.BERKELEY.EDU (Mike Meyer) writes: > >There is a false implication in the above: that it doesn't hurt to add >register declerations. There is at least one compiler out there that >effectively allocates registers from the last declared instead of the >first, so that blindly adding registers to code can slow the generatred >code down. My version of K&R states (page 193, section 8.1 "Storage Class Specifiers)": A register declaration is best thought of as an auto declaration, together with a hint to the compiler that the variables will be heavily used. Only the first few such declarations are effective. ^^^^^ This implies to me that a conforming compiler should allocate "registers" starting with the first declaration.