From owner-freebsd-hackers Thu Nov 4 13:31: 8 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from alcanet.com.au (border.alcanet.com.au [203.62.196.10]) by hub.freebsd.org (Postfix) with ESMTP id 0749514EFC for ; Thu, 4 Nov 1999 13:30:58 -0800 (PST) (envelope-from jeremyp@gsmx07.alcatel.com.au) Received: by border.alcanet.com.au id <40325>; Fri, 5 Nov 1999 08:24:43 +1100 Content-return: prohibited Date: Fri, 5 Nov 1999 08:30:13 +1100 From: Peter Jeremy Subject: Re: Granularity of disk I/O To: freebsd-hackers@FreeBSD.ORG Reply-To: peter.jeremy@alcatel.com.au Message-Id: <99Nov5.082443est.40325@border.alcanet.com.au> MIME-version: 1.0 X-Mailer: Mutt 1.0pre3i Content-type: text/plain; charset=us-ascii Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, 3 Nov 1999 11:37:42 -0800 (PST), Matthew Dillon wrote: > The directory blocking is there for a different reason. Atomicy does not > have much to do with it though perhaps it did at some point in the past. Hmmm... /usr/include/ufs/ufs/dir.h states: * A directory consists of some number of blocks of DIRBLKSIZ * bytes, where DIRBLKSIZ is chosen such that it can be transferred * to disk in a single atomic operation (e.g. 512 bytes on most machines). (Interestingly, DIRBLKSIZ is defined as DEV_BSIZE (== 512) in , 1024 in and 512 in ). If atomicity is no longer a requirement, there would seem to be advantages in changing the directory block size to match the FS block size. In particular, this would reduce the number of unusable fragments at the end of directory blocks (particularly where large filenames are used), and speed up (marginally) skipping empty blocks. Peter To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message