Re: question regarding prelinking
>>>>> On Mon, 20 Jan 2003 09:27:57 +0300, "Nikita V. Youshchenko" <email@example.com> said:
>> So Jack, can you give an example of a program where a significant
>> amount of time is spent having the dynamic linker work out the
>> correct linkage? ie a package that would benefit significantly
>> from prelinking.
>> I'm having a hard time seeing how this will make such a
Nikita> The linking inself (that is, looking up 20000 entries in
Nikita> symbol tables) is noot that long on modern hardware. It may
Nikita> be done in a second or so.
Nikita> Seems that thing that really makes startups SLOW is swapping.
Nikita> During relocation, a shared library page should be changed
Nikita> (by writing new addresses), so this page is unshared (a
Nikita> personal copy of this page for the current process is
Nikita> created), and if there is currently no free physical page, it
Nikita> causes swapping. And swapping IS slow even on modern
Actually, unless I'm misunderstanding something, shared lib pages are
not rewritten (excluding data pages of course). That's what PIC code
is about. A register keeps a pointer to the front of the shared
segment and all refs to a symbol within are based on an offset from
that register. So it's not swapping. If anything it's runtime
slowness not startup.
@James LewisMoss <firstname.lastname@example.org> | Blessed Be!
@ http://people.debian.org/~dres | Linux is kewl!
@"Argue for your limitations and sure enough, they're yours." Bach