Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S263146AbUCMR4D (ORCPT ); Sat, 13 Mar 2004 12:56:03 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S263147AbUCMR4D (ORCPT ); Sat, 13 Mar 2004 12:56:03 -0500 Received: from struggle.mr.itd.umich.edu ([141.211.14.79]:41601 "EHLO struggle.mr.itd.umich.edu") by vger.kernel.org with ESMTP id S263146AbUCMRzQ (ORCPT ); Sat, 13 Mar 2004 12:55:16 -0500 Date: Sat, 13 Mar 2004 12:55:09 -0500 (EST) From: Rajesh Venkatasubramanian X-X-Sender: vrajesh@ruby.engin.umich.edu To: riel@redhat.com cc: linux-kernel@vger.kernel.org, torvalds@osdl.org, andrea@suse.de Subject: Re: anon_vma RFC2 In-Reply-To: Message-ID: References: <20040310080000.GA30940@dualathlon.random> <20040310135012.GM30940@dualathlon.random> <20040312172600.GC30940@dualathlon.random> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1096 Lines: 30 > The only problem is mremap() after a fork(), and hell, we know that's a > special case anyway, and let's just add a few lines to copy_one_pte(), > which basically does: > > if (PageAnonymous(page) && page->count > 1) { > newpage = alloc_page(); > copy_page(page, newpage); > page = newpage; > } > /* Move the page to the new address */ > page->index = address >> PAGE_SHIFT; > > and now we have zero special cases. This part makes the problem so simple. If this is acceptable, then we have many choices. Since we won't have many mms in the anonmm list, I don't think we will have any search complexity problems. If we really worry again about search complexity, we can consider using prio_tree (adds 16 bytes per vma - we cannot share vma.shared.prio_tree_node). The prio_tree easily fits for anonmm after linus-mremap-simplification. Rajesh - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/