From owner-cvs-src Sat Feb 15 17:24:40 2003 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 721AF37B401; Sat, 15 Feb 2003 17:24:38 -0800 (PST) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9AC6B43F93; Sat, 15 Feb 2003 17:24:36 -0800 (PST) (envelope-from bde@zeta.org.au) Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id MAA26519; Sun, 16 Feb 2003 12:24:34 +1100 Date: Sun, 16 Feb 2003 12:25:10 +1100 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Juli Mallett Cc: Kirk McKusick , , , Subject: Re: cvs commit: src/sbin/newfs mkfs.c src/sys/ufs/ffs ffs_alloc.c ffs_vfsops.c In-Reply-To: <20030214153328.A78405@FreeBSD.org> Message-ID: <20030216121332.Y20233-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-cvs-src@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 14 Feb 2003, Juli Mallett wrote: > * De: Kirk McKusick [ Data: 2003-02-14 ] > [ Subjecte: cvs commit: src/sbin/newfs mkfs.c src/sys/ufs/ffs ffs_alloc.c ffs_vfsops.c ] > > mckusick 2003/02/14 13:31:58 PST > > > > Modified files: > > sbin/newfs mkfs.c > > sys/ufs/ffs ffs_alloc.c ffs_vfsops.c > > Log: > > Replace use of random() with arc4random() to provide less guessable > > values for the initial inode generation numbers in newfs and for > > newly allocated inode generation numbers in the kernel. > > Are the sequences for it also repeatable in the newfs case for e.g. the > regression tests, where it is used unseeded? Probably not. Randomness caused me problems in the kernel when I tried to figure out why soft-updates allocated blocks more 10-30% more pessimally than !soft-updates (for the benchmark of reading back files in creation order after untarring /usr/src to a new file system and remounting). I just ifdefed out the randomness, but should have done more for cylinder group allocation since the pessimization might depend on that. IIRC, soft-updates gives some randomness anyway because it delays some allocations. The pessimization seemed to have something to do with not putting blocks in such a good place for delayed allocations. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-src" in the body of the message