Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!burl!ulysses!bellcore!decvax!decwrl!amdcad!lll-crg!topaz!bentley!kwh From: kwh@bentley.UUCP (KW Heuer) Newsgroups: net.lang.c Subject: Inline functions (was: Long longs) Message-ID: <612@bentley.UUCP> Date: Thu, 6-Mar-86 12:33:51 EST Article-I.D.: bentley.612 Posted: Thu Mar 6 12:33:51 1986 Date-Received: Sat, 8-Mar-86 21:27:28 EST References: <491@faron.UUCP> <3408@umcp-cs.UUCP>, <193@rexago1.UUCP> Organization: AT&T Bell Laboratories, Liberty Corner Lines: 16 Keywords: inline functions SYSV 3b2/300 In article <193@rexago1.UUCP> rexago1!rich (K. Richard Magill) writes: >In article <3408@umcp-cs.UUCP> chris@umcp-cs.UUCP (Chris Torek) writes: >>One method, used in the 4BSD kernel and in Franz Lisp, is to write >>a `sed' script, and run the output of the compiler through this. >>Thus what looks like a function call is actually expanded in-line: [ example of such a shell script ] >Paraphrased from "Maxicomputing in Microspace", (WE32100 info manual >select code 451-000): > Under the -O option the compiler expands functions inline providing, > 1) the function has no local variables 2) no registers are saved 3) > the function appears in the same file. ... Irrelevant to the original discussion. The shell script is for inline expansion of what would otherwise be a function call to an *assembler* function, consisting of a single instruction. I seriously doubt that the optimizer could handle that.