From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18406 invoked by alias); 25 May 2013 19:20:41 -0000 Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: glibc-bugs-owner@sourceware.org Received: (qmail 18323 invoked by uid 55); 25 May 2013 19:20:35 -0000 From: "neleai at seznam dot cz" To: glibc-bugs@sourceware.org Subject: [Bug stdio/4099] Overly agressive caching by stream i/o functions. Date: Sat, 25 May 2013 19:20:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: stdio X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: enhancement X-Bugzilla-Who: neleai at seznam dot cz X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-05/txt/msg00228.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=4099 --- Comment #3 from Ondrej Bilka --- On Sat, May 25, 2013 at 12:55:48PM +0000, bugdal at aerifal dot cx wrote: > http://sourceware.org/bugzilla/show_bug.cgi?id=4099 > > Rich Felker changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > CC| |bugdal at aerifal dot cx > > --- Comment #2 from Rich Felker --- > mmap is not the solution; mmap-by-default is not an option because it will > SIGBUS under circumstances you cannot control. The solution is just decoupling > cache size from st_blksize, either never using st_blksize at all (and avoiding > the expensive fstat syscall at open time if possible) or only using it when > it's less than a reasonable upper bound like 8-64k. > For reading my comment was relevant unless you could find how produce SIGBUS for fopen(foo,"rm"). Writing is different issue, a good upper bound looks ok (But I would prefer to flush once per 100ms or so.) -- You are receiving this mail because: You are on the CC list for the bug.