Re: [PATCH 1/2] mm: support fastpath if NUMA is enabled with numa off
From: Matthew Wilcox
Date: Wed Jun 16 2021 - 13:34:12 EST
On Wed, Jun 16, 2021 at 05:37:41PM +0900, Janghyuck Kim wrote:
> Architecture might support fake node when CONFIG_NUMA is enabled but any
> node settings were supported by ACPI or device tree. In this case,
> getting memory policy during memory allocation path is meaningless.
>
> Moreover, performance degradation was observed in the minor page fault
> test, which is provided by (https://lkml.org/lkml/2006/8/29/294).
> Average faults/sec of enabling NUMA with fake node was 5~6 % worse than
> disabling NUMA. To reduce this performance regression, fastpath is
> introduced. fastpath can skip the memory policy checking if NUMA is
> enabled but it uses fake node. If architecture doesn't support fake
> node, fastpath affects nothing for memory allocation path.
This patch doesn't even apply to the current kernel, but putting that
aside, what's the expensive part of the current code? That is,
comparing performance stats between this numa_off enabled and numa_off
disabled, where do you see taking a lot of time?