tech-kern archive

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

Re: posix shared memory



hi,

> Hi,
> 
> yamt%mwd.biglobe.ne.jp@localhost (YAMAMOTO Takashi) wrote:
>> i have userland implementation of posix shared memory.
>> (attached)
>> 
>> rmind proposed a kernel implementation while ago.
>> http://mail-index.netbsd.org/tech-kern/2009/07/30/msg005599.html
>> (thus cc:)
>> 
>> which way should we go?
>> 
>> IMO userland implementation is better because:
>>      - simpler
>>      - smaller
>>      - a bug would have less impact
>>      - "locking object in memory" functionality is better to be
>>        implemented with more generic api like fcntl if necessary
> 
> We should go with the userland implementation.  After some though I
> basically agree with you that facilities like memory locking can be
> implemented with fcntl, mount option tmpfs or whatever.
> 
> However, I would say it would be better to create tmpfs partition
> for this.  A while ago I came up with practically same code, but
> also checking for the fs type:
> 
> http://www.netbsd.org/~rmind/shm.c

i don't think it's a good idea to force fstype.
if we want to recommend tmpfs, it's a job for sysinst, not libc.

YAMAMOTO Takashi

> 
>> 
>> YAMAMOTO Takashi
> 
> -- 
> Mindaugas


Home | Main Index | Thread Index | Old Index