From owner-cvs-all@FreeBSD.ORG Sat Mar 12 00:37:20 2005 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DB91316A4CE; Sat, 12 Mar 2005 00:37:20 +0000 (GMT) Received: from pittgoth.com (14.zlnp1.xdsl.nauticom.net [209.195.149.111]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2405643D41; Sat, 12 Mar 2005 00:37:20 +0000 (GMT) (envelope-from trhodes@FreeBSD.org) Received: from mobile.pittgoth.com (ip68-230-188-82.dc.dc.cox.net [68.230.188.82]) (authenticated bits=0) by pittgoth.com (8.12.10/8.12.10) with ESMTP id j2C0bIMp002789 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Fri, 11 Mar 2005 19:37:19 -0500 (EST) (envelope-from trhodes@FreeBSD.org) Date: Fri, 11 Mar 2005 19:37:12 -0500 From: Tom Rhodes To: Nate Lawson Message-ID: <20050311193712.236d804a@mobile.pittgoth.com> In-Reply-To: <200503112327.j2BNRkGq052260@repoman.freebsd.org> References: <200503112327.j2BNRkGq052260@repoman.freebsd.org> X-Mailer: Sylpheed-Claws 1.0.1 (GTK+ 1.2.10; i386-portbld-freebsd6.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit cc: cvs-src@FreeBSD.org cc: src-committers@FreeBSD.org cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/fs/msdosfs msdosfs_conv.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Mar 2005 00:37:21 -0000 On Fri, 11 Mar 2005 23:27:46 +0000 (UTC) Nate Lawson wrote: > njl 2005-03-11 23:27:46 UTC > > FreeBSD src repository > > Modified files: > sys/fs/msdosfs msdosfs_conv.c > Log: > The mbnambuf routines combine multiple substrings into a single > long filename. Each substring is indexed by the windows ID, a > sequential one-based value. The previous code was extremely slow, > doing a malloc/strcpy/free for each substring. > > This code optimizes these routines with this in mind, using the ID > to index into a single array and concatenating each WIN_CHARS chunk > at once. (The last chunk is variable-length.) > > This code has been tested as working on an FS with difficult filename > sizes (255, 13, 26, etc.) It gives a 77.1% decrease in profiled > time (total across all functions) and a 73.7% decrease in wall time. > Test was "ls -laR > /dev/null". > > Per-function time savings: > mbnambuf_init: -90.7% > mbnambuf_write: -18.7% > mbnambuf_flush: -67.1% > > MFC after: 1 month > > Revision Changes Path > 1.40 +42 -37 src/sys/fs/msdosfs/msdosfs_conv.c > That's hot. :) -- Tom Rhodes