Article View: fa.netbsd.tech.kern
Article #100Re: posix shared memory
From: YAMAMOTO Takashi
Date: Wed, 08 May 2013 23:50
Date: Wed, 08 May 2013 23:50
45 lines
3072 bytes
3072 bytes
hi, > On Tue, Apr 02, 2013 at 02:27:15AM +0000, YAMAMOTO Takashi wrote: >> > yamt@mwd.biglobe.ne.jp (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 >> > >> > 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. > > Wouldn't the choice of filesystem have a significant impact on the > behaviour? (speed, persistence, need for an actual disk, etc...) yes. wrt persistence, i guess something similar to /etc/rc.d/cleartmp is good enough, though. > Perhaps forcing it might not be a good idea, but it seems like > requiring something to be configured, and not having a good default > that is known to work, will cause an unnecessary waste of time > for anyone that might try to use this. yes. as far as i know there are few users of this api in the field. so it's difficult for me to guess expectations. eg. how large the filesystem should be? rhel seems to use "half of ram". it's their tmpfs's default. solaris doesn't seem to use a dedicated filesystem. it just uses /tmp. (with some name mangling) YAMAMOTO Takashi > > eric
Technical Details
Message-ID:
<fa.h4sq+pAKuTDxy8rHOlPzSnkMSPU@ifi.uio.no>Path:
arc1-ca.pugleaf.net!bp1ni1862pbd.1!nntp.google.com!news.glorb.com!news.unit0.net!uio.no!nntp.uio.no!.POSTED!not-for-mailReferences:
<fa.DiUhLeRLRhFzsNj0T1mH8bW9JN4@ifi.uio.no>Show Full Headers
Complete Article Headers
X-Google-Thread: 10c6f4,c8504c1ed5e12aa5
X-Google-NewGroupId: yes
X-Google-Attributes: gidb7e13b6095,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
X-Received: by 10.66.226.233 with SMTP id rv9mr1892264pac.42.1368057018005;
Wed, 08 May 2013 16:50:18 -0700 (PDT)
Path: arc1-ca.pugleaf.net!bp1ni1862pbd.1!nntp.google.com!news.glorb.com!news.unit0.net!uio.no!nntp.uio.no!.POSTED!not-for-mail
From: yamt@mwd.biglobe.ne.jp (YAMAMOTO Takashi)
Newsgroups: fa.netbsd.tech.kern
Subject: Re: posix shared memory
Date: Wed, 08 May 2013 23:50:17 UTC
Organization: Internet mailing list
Lines: 45
Sender: tech-kern-owner@NetBSD.org
Message-ID: <fa.h4sq+pAKuTDxy8rHOlPzSnkMSPU@ifi.uio.no>
References: <fa.DiUhLeRLRhFzsNj0T1mH8bW9JN4@ifi.uio.no>
NNTP-Posting-Host: mail-jess.uio.no
Mime-Version: 1.0
X-Trace: readme.uio.no 1368057017 5207 129.240.7.9 (8 May 2013 23:50:17 GMT)
X-Complaints-To: abuse@uio.no
NNTP-Posting-Date: Wed, 8 May 2013 23:50:17 +0000 (UTC)
Cc: rmind@netbsd.org, tech-userlevel@netbsd.org, tech-kern@netbsd.org
To: erh@nimenees.com
Delivered-To: tech-kern@netbsd.org
In-Reply-To: Your message of "Tue, 2 Apr 2013 15:24:57 -0500"
<20130402202457.GA4795@nimenees.com>
X-Mailer: Cue version 0.8 (111031-0948/takashi)
List-Id: tech-kern.NetBSD.org
Original-Date: Wed, 8 May 2013 23:49:33 +0000 (UTC)
Original-Message-Id: <20130508234933.901D314A14A@mail.netbsd.org>
Original-References: <20130402202457.GA4795@nimenees.com>
Content-Type: Text/Plain; charset=us-ascii