* Daniel Burrows said: > On Tue, Aug 17, 1999 at 04:54:50PM -0400, Steve Willer was heard to say: > > > No memory cost? Care to rethink that again? > > > > I have been rethinking it, but as far as I can tell from reading the ldso > > source and from knowing a little bit about how linkers work, there is no > > RAM benefit from using shared libraries. The benefit is on the maintenance > > side, having shared code sitting in a single file. If you can point me to > > a page that explains where I'm wrong (if I am), then please do. > > *blink* > > Now _I'm_ confused. My understanding was that the library is loaded into > memory only once and shared between different processes (possibly with > copy-on-write set for the relevant pages), the same way that (eg) > one copy of bash is shared between every running bash process. Thus the term > 'shared library'. Yes, but think of it as a tree structure - everything below the current node inherits what's loaded on the parent node. Thus, everything loaded by init is shared by all the processes - namely the libc6 code and the roundabouts. If you need anything more to be shared in that way, use the pre-loading feature. marek
Attachment:
pgpm3yw84r_v8.pgp
Description: PGP signature