From owner-cvs-src@FreeBSD.ORG Sun Sep 24 08:23:48 2006 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 12EF216A403; Sun, 24 Sep 2006 08:23:48 +0000 (UTC) (envelope-from bde@zeta.org.au) Received: from mailout1.pacific.net.au (mailout1.pacific.net.au [61.8.0.84]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8FCF843D5A; Sun, 24 Sep 2006 08:23:47 +0000 (GMT) (envelope-from bde@zeta.org.au) Received: from mailproxy2.pacific.net.au (mailproxy2.pacific.net.au [61.8.2.163]) by mailout1.pacific.net.au (Postfix) with ESMTP id D266832867F; Sun, 24 Sep 2006 18:23:45 +1000 (EST) Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailproxy2.pacific.net.au (8.13.4/8.13.4/Debian-3sarge3) with ESMTP id k8O8Ng9I013977; Sun, 24 Sep 2006 18:23:43 +1000 Date: Sun, 24 Sep 2006 18:23:41 +1000 (EST) From: Bruce Evans X-X-Sender: bde@delplex.bde.org To: Tim Kientzle In-Reply-To: <45156E4E.6040806@kientzle.com> Message-ID: <20060924165852.O74016@delplex.bde.org> References: <200609150804.k8F84O1H056038@repoman.freebsd.org> <20060915155912.GA71796@xor.obsecurity.org> <450AD508.10608@freebsd.org> <20060915180315.GB74735@xor.obsecurity.org> <450C30ED.7090901@freebsd.org> <20060916192437.GA15425@xor.obsecurity.org> <45156E4E.6040806@kientzle.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: src-committers@FreeBSD.org, Andre Oppermann , cvs-src@FreeBSD.org, cvs-all@FreeBSD.org, Tim Kientzle , Ruslan Ermilov , Kris Kennaway Subject: Re: bsdtar vs gtar performance X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Sep 2006 08:23:48 -0000 On Sat, 23 Sep 2006, Tim Kientzle wrote: > Kris and Ruslan were recently discussing the performance of bsdtar > relative to gtar, which prompted me to do some measurements > of my own. I used /usr/ports as my test, because it stresses > file and directory creation over extracting large files. > > Here are some initial results, based on ten runs of each test on a > quiescent system, comparing results with PHK's "ministat": > > [... ones with no difference] > > * Extracting uncompressed archives: gtar is about 13% faster > than bsdtar in my test. Interestingly (to me), this was the same > with or without -m. (I've long suspected dir timestamp restores > as a contributor; this shows otherwise.) Changes to attributes by syscalls (utimes(), chown()... are always written asynchronously, so -m should always have little effect. A quick test showed that the main difference for extraction is that bsdtar does an lchmod() for every file extracted. gtar apparently optimizes away null chmod()'s. I would expect -m to make little difference for bsdtar since the writes for the changes to the attributes from utimes() + lchmod() are coalesced, but for gtar -m would be noticeable faster since it usually eliminates these writes. Bruce