On 2010-06-15, JMGross <[email protected]> wrote:
> The suggested compiler/linker flags, however, let the compiler treat
> each function as a separate compilation unit, starting at its own
> 0-offset address. This means teh compiler will not resolve any local
> references and let it all to the linker. Since all references are
> passed to the linker, the linker can link or discard every of these
> sections depending on the open references. What's references from a
> different module is kept, what's not referenced will be discarded.
> But it may happen that parts are discarded bwcause not yet referenced
> by any of the already loaded modules, bu twill be later and then the
> reference cannot be resolved as the target had been discarded
> already.
If that happens, it's a bug. Can you post an example of that so it can
be fixed?
> Also, it keeps the compiler for doing optimizations like common
> subexpression elimination or using the most efficient way to call
> functions or access variables, as they are all referenced as
> externals.
I'd also be interested in seeing examples of that.
--
Grant Edwards grant.b.edwards Yow! I'm a nuclear
at submarine under the
gmail.com polar ice cap and I need
a Kleenex!