Inline functions (was: Long longs)

KW Heuer kwh at bentley.UUCP
Fri Mar 7 03:33:51 AEST 1986


In article <193 at rexago1.UUCP> rexago1!rich (K. Richard Magill) writes:
>In article <3408 at umcp-cs.UUCP> chris at 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.



More information about the Comp.lang.c mailing list