low level optimization

Blair P. Houghton bhoughto at bishop.intel.com
Fri Apr 19 13:44:10 AEST 1991


In article <21812 at lanl.gov> jlg at cochiti.lanl.gov (Jim Giles) writes:
>In article <1991Apr17.225944.15261 at zoo.toronto.edu>, henry at zoo.toronto.edu (Henry Spencer) writes:
>|> [...] You do interprocedural analysis across all source files
>|>supplied to a single invocation of the compiler,  [...]
>
>And, if you subsequently change _some_ of those source files?  What 
>then?  Under this model, you'd have to recompile _all_ the others 
>that were originally compiled together.  This violates one of the 
>principle reasons to have separate compilation to begin with - the 
>elimination of the needto recompile most of your code every time 
>you change a piece of it.

ANSI X3.159-1989, sec. 2.1.2.3, p. 8, l. 30:
"...issues of optimization are irrelevant."

The only reason you need to recompile (in this situation,
from the information given) is to provide the compiler
enough information to optimize a certain subset of the
syntax.  If you want optimizations of this sort, you must:

    (a) use a compiler which provides this optimization;
    (b) write a makefile that indicates the dependencies
	inherent in this optimization; and,
    (c) run make(1) instead of cc(1).

Neither are any of these things specified by the standard,
nor are any of them prohibited to be used in concert with a
conforming implementation of the C language.

Basically, if you want to do something outside the realm of
all sensibility, you may have to hold its hand.

				--Blair
				  "And you'll _still_ spend less time each
				   day recompiling source files than you do
				   shaking your penis dry at the urinal."



More information about the Comp.lang.c mailing list