From owner-freebsd-hackers Mon Apr 19 16:47:57 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from apollo.backplane.com (apollo.backplane.com [209.157.86.2]) by hub.freebsd.org (Postfix) with ESMTP id 7E04F151FA for ; Mon, 19 Apr 1999 16:47:55 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.9.3/8.9.1) id QAA91499; Mon, 19 Apr 1999 16:45:27 -0700 (PDT) (envelope-from dillon) Date: Mon, 19 Apr 1999 16:45:27 -0700 (PDT) From: Matthew Dillon Message-Id: <199904192345.QAA91499@apollo.backplane.com> To: Zhihui Zhang Cc: hackers@FreeBSD.ORG Subject: Re: Directories not VMIO cached at all! References: Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Ack! I would not apply that patch to the 2.2.x tree. I recommend you back it out. It probably didn't work because you didn't make all the necessary changes, but I have not researched what changes would be necessary to make it work for 2.2.x. While conceptually simple, it would be fairly dangerous to just patch it into 2.2.x without a considerable amount of testing. Also, the test you are running is not going to time directory lookups very well because you are exec'ing 'grep' for each file. Try doing the find and redirecting to /dev/null. Like this: time find -x /usr/src > /dev/null time find -x /usr/src > /dev/null time find -x /usr/src > /dev/null (But you still may not see an improvement) -Matt Matthew Dillon :I tried to apply your patch to FreeBSD 2.2.8. I only made changes to file :vfs_subr.c (vfs_object_create()) and vfs_vnops.c (vn_open()) because I can :not find the corresponding places in file vfs_lookup.c and vfs_syscalls.c. : :After this, I made a new kernel and reboot. I issue the following :command: : : # find /usr/src -name "*.?" -exec grep "dummy" /dev/null {} \; : :It takes about five minutes as it did before I modified the kernel and :reboot. So obviously the modifications I made are not enough. I should :change something else to really use it. Can you please tell me where to :look at in 2.2.8? Somewhere in namei()? : :I believe your idea is a good one because it may help to solve the :directory layout problem when you do depth-first search of directories (as :in find?). The reason I need it now is that each time I spend 5 minutes :to search for a symbol in the source code tree under /usr/src. : :Thanks for your help. : :-Zhihui To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message