From owner-freebsd-hackers Thu Jul 29 11:59:20 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 8298815114 for ; Thu, 29 Jul 1999 11:59:17 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.9.3/8.9.1) id LAA77496; Thu, 29 Jul 1999 11:58:24 -0700 (PDT) (envelope-from dillon) Date: Thu, 29 Jul 1999 11:58:24 -0700 (PDT) From: Matthew Dillon Message-Id: <199907291858.LAA77496@apollo.backplane.com> To: Jason Thorpe Cc: "Daniel C. Sobral" , hackers@FreeBSD.ORG Subject: Re: MADV_SEQUENTIAL and GNU Grep References: <199907291756.KAA00408@lestat.nas.nasa.gov> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG :Why? I can think of at least one instance where this is useful: using :a file in the file system as a shared memory handle. : :Seems as if the programmer erroneously MADV_FREE's a file, well ... you :only supplied the rope. : : -- Jason R. Thorpe My main worry here, putting it into words, is that malloc() uses MADV_FREE all over the place. If a program gets corrupted due to bugs in the program and winds up corrupting malloc, I worry that the result could be bogus madvise() calls that destroy mmap()'d files that the program happens to be using at the time. It may not be a justifiable worry, but it is enough that I am not gung-ho about implementing MADV_FREE on file mmaps. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message