POV-Ray : Newsgroups : povray.off-topic : Linking : Re: Linking Server Time
1 Jul 2024 02:05:33 EDT (-0400)
  Re: Linking  
From: clipka
Date: 28 May 2016 23:59:14
Message: <574a6912$1@news.povray.org>
Am 28.05.2016 um 09:47 schrieb Orchid Win7 v1:


> allows you to write functions that call functions that don't exist. This
> leaves you with an object file containing unresolved references. The
> linker then resolves these references.
> 

> designed this for only has 2KB of memory implemented as a mercury delay
> line" or some such stupidity... ]

No. The "some reason" is that you don't want to have to recompile your
entire project just because some minor modification in a single obscure
C source file has caused all your memory addresses to shift.

Therefore, each and every (!) C source file is first translated
("compiled") into an address-independent (*) object file, and in a later
step all the object files in your project are combined ("linked") into a
single executable with fixed addresses.

(* To achieve address independency, a similar approach is used as for
external symbols: A table is included in the object file listing each
and every memory location that will have to hold an absolute address in
the executable, but in the object file only holds an offset relative to
the object file's "payload".)


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.