Re: [PATCH v2] perf/aux: Avoid reclaim for optional higher-order allocations

From: Yabin Cui

Date: Wed Nov 25 2026 - 13:13:59 EST


On Wed, 25 Nov 2026 11:54:53 +0000, Leo Yan <leo.yan@xxxxxxx> wrote:
> PERF_AUX_GFP includes GFP_KERNEL, which contains __GFP_RECLAIM. On
> fragmented systems, costly AUX allocations can wake kswapd. When perf
> falls back to lower orders, the allocating task can stall in direct
> reclaim or compaction. Yabin Cui reported that the resulting memory
> pressure can trigger Android's lmkd to kill applications.
>
> [ ... ]
>
> Reported-by: Yabin Cui <yabinc@xxxxxxxxxx>
> Link: https://lore.kernel.org/lkml/CALJ9ZPO9XxF-kz5K67Jg8RtpiEmK7XFU3e+xDak6LyV_We7yBQ@xxxxxxxxxxxxxx/
> Suggested-by: Yabin Cui <yabinc@xxxxxxxxxx>
> Signed-off-by: Leo Yan <leo.yan@xxxxxxx>

Thanks for updating v2, Leo!

Tested-by: Yabin Cui <yabinc@xxxxxxxxxx>