Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Mac OS X File IO Performance Issue?




On Jul 29, 2005, at 10:00 AM, Elliott Hughes wrote:

On 2005-07-29, at 09:53, Shawn Erickson wrote:
On Jul 29, 2005, at 9:45 AM, Elliott Hughes wrote:
Mac OS doesn't get much faster, no matter how many times you read something.

This was part of your statement and it isn't true in general (maybe in specific to meta data), that is what my examples show and what I was responding to.

indeed, but it *is* true for the situations the original poster and i were talking about. my statement is perhaps misleading unless you've experienced both Linux and Mac OS doing the exact same job, in which case you know that i mean: "Linux gets *MUCH* faster; insanely, unbelievably fast. Mac OS gets slightly faster."

I see the following in a grep test against a set of files (100 folders deep tree with 100 files in each folder each 4KB in size). This test was done after restarting the system so none of the file exist in the file cache.


[G5:~/test] shawnce% time grep -a -R 666 dir_0 > /dev/null
0.278u 2.918s 0:15.82 20.1%     0+0k 411+518io 0pf+0w

The above is IO bound and was processing about 3,427 files a second or about 13 MB/s.

[G5:~/test] shawnce% time grep -a -R 666 dir_0 > /dev/null
0.122u 0.320s 0:00.44 100.0%    0+0k 0+0io 0pf+0w

The above is CPU bound and was processing about 31,250 files a second or about 122 MB/s.

I see decient speed up because of the file cache what do folks see on a typical linux system? I don't have one handy at the moment (not that this is staying generally relevant to Java of Mac OS X).

Also I noted that no IO to disk (in either direction) appears to have taken place on the second run just on the first run. So it looks like the file cache is holding all that is needed and the file system state is processed in RAM.

FYI I built the file test tree with the following simple sh script...

depth=0
while [ "$depth" -lt 100 ]; do
        mkdir "dir_${depth}"
        cd "dir_${depth}"

filecount=0
while [ "$filecount" -lt 100 ]; do
dd bs=4096 if=/dev/random of="testfile_${filecount}" count=1


                ((filecount++))
        done

        ((depth++))
done

-Shawn

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/java-dev/email@hidden

This email sent to email@hidden
References: 
 >Re: Mac OS X File IO Performance Issue? (From: Elliott Hughes <email@hidden>)
 >Re: Mac OS X File IO Performance Issue? (From: Shawn Erickson <email@hidden>)
 >Re: Mac OS X File IO Performance Issue? (From: Elliott Hughes <email@hidden>)
 >Re: Mac OS X File IO Performance Issue? (From: Shawn Erickson <email@hidden>)
 >Re: Mac OS X File IO Performance Issue? (From: Elliott Hughes <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.