From owner-freebsd-hackers Thu Jul 29 9:27:52 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 7666514C2D for ; Thu, 29 Jul 1999 09:27:49 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.9.3/8.9.1) id JAA74429; Thu, 29 Jul 1999 09:26:12 -0700 (PDT) (envelope-from dillon) Date: Thu, 29 Jul 1999 09:26:12 -0700 (PDT) From: Matthew Dillon Message-Id: <199907291626.JAA74429@apollo.backplane.com> To: "Daniel C. Sobral" Cc: hackers@FreeBSD.ORG Subject: Re: MADV_SEQUENTIAL and GNU Grep References: <199907290439.XAA69977@celery.dragondata.com> <199907290445.VAA66252@apollo.backplane.com> <37A05F22.5AA2D27D@newsguy.com> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG :So it works, then? GNU grep has this #ifdef'ed out, with a comment :about it impacting negatively on performance on BSD 4.1. I recall :some rants on this subject a couple of years ago... If it is :working, I'd like to change that 0 to 1 in our tree. : :-- :Daniel C. Sobral (8-DCS) Yes, it will work. Oops. I do see one problem though... if you do this the underlying file object will be marked for sequential operation even after the grep (in this case) exits. That is, an madvise() of MADV_NORMAL, SEQUENTIAL, or RANDOM appears to have a permanent effect on the object. This is probably not correct behavior. We could probably fix this by moving this particular flag from the object to the vm_entry. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message