Date: Sat, 18 Feb 2006 23:17:52 -0500 From: Mark Bucciarelli <mark@gaiahost.coop> To: freebsd-performance@freebsd.org Subject: Re: stat speed Message-ID: <20060219041752.GU2756@rabbit> In-Reply-To: <20060219040656.GT2756@rabbit> References: <20060219040656.GT2756@rabbit>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Feb 18, 2006 at 11:06:57PM -0500, Mark Bucciarelli wrote: > I'm curious how fast stat is. > > I generated a list of 200,000 file names > > # find / | head -200000 > files.statspeed > > then ran a million iterations of randomly picking a file name and > stating it (see attached program). Hmmm, 200,000 files 1,000,000 iterations. On avg, each file hit five times. Uhh, that's not a good way to avoid caching. Doh. Wow, caching is pretty amazing. I just reran the program, this time using 500,000 file paths and only stat'ing 10,000 of them. The first run was 99,059/second, the second was 188,239. So I guess 100,000/second is about right on my system w/o cache. m
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060219041752.GU2756>