Re: [PATCH v7 01/28] mm: Optimise nth_page for contiguous memmap

2021-04-12 Thread Christoph Hellwig
On Fri, Apr 09, 2021 at 07:50:38PM +0100, Matthew Wilcox (Oracle) wrote: > Signed-off-by: Matthew Wilcox (Oracle) Looks good, Reviewed-by: Christoph Hellwig

[PATCH v7 01/28] mm: Optimise nth_page for contiguous memmap

2021-04-09 Thread Matthew Wilcox (Oracle)
If the memmap is virtually contiguous (either because we're using a virtually mapped memmap or because we don't support a discontig memmap at all), then we can implement nth_page() by simple addition. Contrary to popular belief, the compiler is not able to optimise this itself for a vmemmap