Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Reply-To: Cygwin List Message-Id: <6.0.1.1.0.20040412094838.0287bc58@127.0.0.1> X-Sender: Date: Mon, 12 Apr 2004 09:50:49 -0400 To: Vinay Kumar , cygwin AT cygwin DOT com From: Larry Hall Subject: Re: performance degradation because of sparse file handling in cygwin In-Reply-To: References: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" At 11:37 AM 4/12/2004, you wrote: >Hi, > I have some questions about handling of sparse file in cygwin 1.5.5 >onwards. cygwin makes a file as a sparse if there is a write request >beyond 128 KB from file end. I am not sure whether it is a heuristic or >some statistical fact governs the use of 128 KB. Please clarify. >The code of fhandler_base::write in fhandler.cc suggest that the check for >sparse file runs if there has been a seek before write request. The code >performs fine when dealing with local file. For files on network (netapps >or samba) write performance degrades because of this code. If a testcase >performs seek followed by write then each time code checks whether the >file is sparse or not. In that case GetFileSize gets called each time >write is performed, which takes good amount of time on network. >Is there any alternative to GetFileSize which >does not take much time? I searched in MSDN and found none faster than >GetFileSize. I can't speak to that. I suppose one option is to just conditionalize sparse files to local drives. Others may have better ideas though. -- Larry Hall http://www.rfk.com RFK Partners, Inc. (508) 893-9779 - RFK Office 838 Washington Street (508) 893-9889 - FAX Holliston, MA 01746 -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/