Gentoo Archives: gentoo-user

From: Michael Mol <mikemol@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Is my system (really) using nptl
Date: Sun, 14 Oct 2012 15:08:45
Message-Id: CA+czFiAo9-cfZDxAZuqGcNJ55ieFqcG2r4_SD6z5mVU+5ndQVA@mail.gmail.com
In Reply to: Re: [gentoo-user] Is my system (really) using nptl by Florian Philipp
1 On Sun, Oct 14, 2012 at 5:31 AM, Florian Philipp <lists@×××××××××××.net> wrote:
2 > Am 14.10.2012 01:20, schrieb Michael Mol:
3 >> On Sat, Oct 13, 2012 at 4:18 PM, Canek Peláez Valdés <caneko@×××××.com> wrote:
4 >>> On Sat, Oct 13, 2012 at 2:50 PM, Michael Mol <mikemol@×××××.com> wrote:
5 >>> [snip]
6 >>>> (Well, I'm not certain that POSIX thinks of threads as parents to each other.
7 >>>
8 >>> Hence the reason I put "parent" in quotes, and I specified "actually,
9 >>> the thread that created it".
10 >>>
11 >>>> There are *numerous* IPC mechanisms available on Linux. For starters,
12 >>>> there are sockets (domain, IPv4, IPv6, et al), named pipes, signals,
13 >>>> mmap()'d files, messaging, etc.
14 >>>
15 >>> Yeah, none of them "easy and quickly" to use, or at least not if you
16 >>> compare it with shared memory.
17 >>
18 >> I assume you mean 'shared memory' in the 'many threads to an address
19 >> space', not the /dev/shm sense.
20 >>
21 >
22 > If we really want to be nit-picking, we have to assume 'shared memory'
23 > as in malloc'ed [1] or stack memory. Anonymous mmap'ed memory mappings
24 > are preserved across forks and changes in them can be shared since
25 > kernel 2.4.
26
27 Absolutely.
28
29 > [1] Yes, I know that malloc uses mmap but its mappings are MAP_PRIVATE.
30
31 For the GNU libc, yeah. I noticed that in strace, and was amused.
32
33 --
34 :wq

Replies

Subject Author
Re: [gentoo-user] Is my system (really) using nptl Florian Philipp <lists@×××××××××××.net>