From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id C3090C54E94 for ; Thu, 26 Jan 2023 01:12:05 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 4ABF16B0071; Wed, 25 Jan 2023 20:12:05 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 45BF06B0073; Wed, 25 Jan 2023 20:12:05 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 3288D6B0071; Wed, 25 Jan 2023 20:12:05 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 1F01A6B0071 for ; Wed, 25 Jan 2023 20:12:05 -0500 (EST) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id D4720C0EB9 for ; Thu, 26 Jan 2023 01:12:04 +0000 (UTC) X-FDA: 80395173768.05.709C2CD Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf14.hostedemail.com (Postfix) with ESMTP id 2CA2F100002 for ; Thu, 26 Jan 2023 01:12:01 +0000 (UTC) Authentication-Results: imf14.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=SEHIvHlU; dmarc=none; spf=pass (imf14.hostedemail.com: domain of akpm@linux-foundation.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1674695522; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=weUA4I9LTXRoDJU+Yw1p0d5HAStOb0t8RvqMreJB/6E=; b=d7P7JR8BowkTa8AVc9GlADwuqkoAdsmyrzEjfAbaewSLzZleCc60gHD2J53hIaPwDr4EPD I94zW5wJtDQO4aR1x0oLps68lNdPSJJKcJQDVelovU9oTcRj//nerHFL+H4yW39cydLk/C VwCx+q+MaUCdM29wu4cIXvMqKtiaKVE= ARC-Authentication-Results: i=1; imf14.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=SEHIvHlU; dmarc=none; spf=pass (imf14.hostedemail.com: domain of akpm@linux-foundation.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1674695522; a=rsa-sha256; cv=none; b=6+zlLfub9sazzZS0YeXIvzcPDXnaXqOGDeYacU1l5Bm2Uhp9NfWSYC8SjO0rqn7qNurFid UaFheoUqfINiiFIShqCN/tTVFTcOTQvXtmdNGrkAfcGEvsJrIbDUSfEZghQKA7xBEBvq7V YL+HMtwe0s+pze3cEgl5TG/IxLqM2gQ= Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 2056061715; Thu, 26 Jan 2023 01:12:01 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 205D9C433D2; Thu, 26 Jan 2023 01:12:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1674695520; bh=1tJKpxAhIejZkUCqagAyMqyekFlm2a9vKsTefDdUQko=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=SEHIvHlUl8jnqGBhCsBW+SE1kz/1D1fJ1LsUuAyFOiZ/9sVQGKEG/36iKHXexxgXL tloDqkTeZpLikItZFTRx30NAkkXWAzVGULr+kXkAWrMvIDvRCCatQ1QUvCZyBXGBUT XmcU7I5EDqxIBUD9CzgaS7RkC1qdqdYSUEusMuwk= Date: Wed, 25 Jan 2023 17:11:59 -0800 From: Andrew Morton To: Mel Gorman Cc: Vlastimil Babka , Jiri Slaby , Maxim Levitsky , Michal Hocko , Pedro Falcato , Paolo Bonzini , Chuyi Zhou , Linux-MM , LKML Subject: Re: [RFC PATCH 0/4] Fix excessive CPU usage during compaction Message-Id: <20230125171159.355a770a2e34f78d7664e1f0@linux-foundation.org> In-Reply-To: <20230125134434.18017-1-mgorman@techsingularity.net> References: <20230125134434.18017-1-mgorman@techsingularity.net> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspam-User: X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: 2CA2F100002 X-Stat-Signature: kmxqiajfaznbqju5co4u1ocidxfcxzia X-HE-Tag: 1674695521-676144 X-HE-Meta: U2FsdGVkX194lfgu6JbOXl9fRCm6zc1b6Jzl3UeSq0dJLZs6ZUYhNB14Ym0oXWlNfw2MYmekp7W0jSdi5ic2WsmJ+OCQbitwt3hstTrMqLNWtE1hJ7vPkXnIwTCW9b2tK08fq/fRaTwzQNZJO+qt4KeN7ZX9KzRUos8LvZ8cHWuqw31TL85ThV7frNpetTET5pbscn5OZ3iCEzY8QapS6G7n7FJUtCR3k9wSADOttROpOVCeIbt+Qj4ACljpIO9Xi8pG3YjeEGscTfZqsY9hwkhhIW/Kruu69B0oQTV3JoIVkqE/BevoZzjzC0EMfOGuI64H/oxv4abYFVhj3MG6ms5ABzMo7uGgSby6BD0jXrel1vSbfzWKAB6Fqik9NTMRv3zVYhZ7/UTuuQSTf2ZeVfSISBAH120nCS+QNljVFtDNT5XJxXURHGcGTCCG5a+hh61KhXGyZC1G4dXFy7fRgKNBsXZ+0RLPnc0A5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loop: owner-majordomo@kvack.org List-ID: On Wed, 25 Jan 2023 13:44:30 +0000 Mel Gorman wrote: > Commit 7efc3b726103 ("mm/compaction: fix set skip in fast_find_migrateblock") > fixed a problem where pageblocks found by fast_find_migrateblock() were > ignored. Unfortunately there were numerous bug reports complaining about high > CPU usage and massive stalls once 6.1 was released. Due to the severity, > the patch was reverted by Vlastimil as a short-term fix[1] to -stable and > is currently sitting in the Andrew's git branch mm/mm-hotfixes-unstable. > > The underlying problem for each of the bugs is suspected to be the > repeated scanning of the same pageblocks. This series should guarantee > forward progress even with commit 7efc3b726103. More information is in > the changelog for patch 4. > > If this series is accepted and merged after the revert of 7efc3b726103 > then a "revert of the revert" will be needed. If we drop Vlastimil's reversion and apply this, the whole series should be cc:stable and it isn't really designed for that. So I think either a) drop Vlastimil's reversion and persuade Mel to send us a minimal version of patch #4 for -stable consumption. Patches 1-3 of this series come later. b) go ahead with Vlastimil's revert for -stable, queue up this series for 6.3-rc1 and redo the original "fix set skip in fast_find_migrateblock" some time in the future. If we go with b) then the Fixes: tag in "[PATCH 4/4] mm, compaction: Finish pageblocks on complete migration failure" is inappropriate - fixing a reverted commit which Vlastimil's revert already fixed. I'll plan on b) for now.