in reply to (tye)Re: collective unconcious (about shared memory...)
in thread collective unconcious (about shared memory...)

>Since IO::Socket::SSL eventually uses some C code, you should be sure to put that code into a shared library. That way that chunk of memory
>will always remain shared between all processes (even if they aren't related) since the shared library is loaded using mmap (or an equivalent).

I'm not sure what you mean by this.

So parents and children share memory, but what about invocations of the Perl interpreter?
That is, if I invoke the same program from different shells, do they share memory? They must use the same shared libs, right?

dshahin

  • Comment on Re: (tye)Re: collective unconcious (about shared memory...)

Replies are listed 'Best First'.
(tye)Re3: collective unconcious (about shared memory...)
by tye (Sage) on Apr 17, 2001 at 22:08 UTC

    Yes, one of the points behind shared libraries is that the read-only sections of those libraries get shared by all processes that use the same library (even if the processes aren't related).

    The parent and child [after fork() but before exec()] have the potential to share a lot more memory.

            - tye (but my friends call me "Tye")