discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] Shared Memory Confusion


From: Marcus Müller
Subject: Re: [Discuss-gnuradio] Shared Memory Confusion
Date: Wed, 26 Nov 2014 17:08:33 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0

Hi Martin,
> Despite what the header says, the sysv implementation doesn't call mmap().
I realize the documentation comments of all the unix circbuffers are
just copypasta...
> Which I say with a 80% confidence, because that's as far as I'll go with
> the circbuff stuff.
I know that "this source code reeks of quicksand" feeling...

We also have mmap()ing implementations, I guess:
vmcircbuf_mmap_shm_open and vmcircbuf_mmap_tmpfile; of which only the
second doesn't use shared memory, which is the last one in the
preference list, but is the one that I'd actually use. Also, in that one
we get a file handler to a temporary file, unlink that directly after,
and just use that handler to be able to ftruncate/mmap memory. which we
could likely also do by just mmap(..., size, ... ,MAP_ANONYMOUS, -1,

So I'm getting more and more confused[1].

Greetings,
Marcus

[1] that doesn't happen very often. I have a fairly high level of base
confusion...



reply via email to

[Prev in Thread] Current Thread [Next in Thread]