From owner-freebsd-hackers Thu Jul 29 11:11:35 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 9EF74150DA for ; Thu, 29 Jul 1999 11:11:23 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.9.3/8.9.1) id LAA77015; Thu, 29 Jul 1999 11:11:18 -0700 (PDT) (envelope-from dillon) Date: Thu, 29 Jul 1999 11:11:18 -0700 (PDT) From: Matthew Dillon Message-Id: <199907291811.LAA77015@apollo.backplane.com> To: Jason Thorpe Cc: "Daniel C. Sobral" , hackers@FreeBSD.ORG Subject: Re: MADV_SEQUENTIAL and GNU Grep References: <199907291742.KAA00237@lestat.nas.nasa.gov> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG :On Thu, 29 Jul 1999 10:21:52 -0700 (PDT) : Matthew Dillon wrote: : : > Shoot, it barely took 10 minutes for me to move the behavior field from : > the object to the vm map entry. : :...make sure the map entries are clipped properly. It's easy to miss this :in the most common test case of advising the entire mapping. : : -- Jason R. Thorpe I believe the code is doing the right thing. Here is an excerpt from vm_map_madvise() in vm_map.c (with the behavior moved to the map entry): for(current = entry; (current != &map->header) && (current->start < end); current = current->next) { vm_size_t size; if (current->eflags & MAP_ENTRY_IS_SUB_MAP) { continue; } vm_map_clip_end(map, current, end); size = current->end - current->start; ... current->behavior = ... ... -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message