low level optimization

Henry Spencer henry at zoo.toronto.edu
Fri Apr 19 04:06:23 AEST 1991


In article <21812 at lanl.gov> jlg at cochiti.lanl.gov (Jim Giles) 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...

Correct.  Arranging to do this is pretty trivial with something like make.
Of course, having to do it is a nuisance.  Using some sort of intermediate
form as the basis for interprocedural analysis could bypass *some* of the
overhead, but having to reprocess all the relevant code to some extent is
really rather fundamental to interprocedural optimization.

>... I'm just pointing out that it _does_ violate the
>standards of both Fortran and C which are defined to be separately
>compiled...

I can't speak for Fortran, but please cite chapter and verse out of X3.159
when you say this about C.  You are, simply, wrong.  You are confusing the
characteristics of specific implementations with what is mandated by the
standard.  There is *nothing* in ANSI C which demands classical separate
compilation or prevents interprocedural analysis.
-- 
And the bean-counter replied,           | Henry Spencer @ U of Toronto Zoology
"beans are more important".             |  henry at zoo.toronto.edu  utzoo!henry



More information about the Comp.lang.c mailing list