Re: [PATCH] mremap: skip page table lookup for non-faulted anonymousVMAs

From: Andrea Arcangeli
Date: Mon Nov 07 2011 - 10:33:03 EST


On Mon, Nov 07, 2011 at 12:21:35PM +0800, Nai Xia wrote:
> If an anonymous vma has not yet been faulted, move_page_tables() in move_vma()
> is not necessary for it.

I actually thought of adding that (in fact fork has it and it's more
likely to be beneficial for fork than for mremap I suspect), but this
adds a branch to the fast path for a case that shouldn't normally
materialize. So I don't think it's worth adding it as I expect it to
add overhead in average.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/