Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp1825882pxb; Mon, 20 Sep 2021 06:16:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw5g6HNTFOO08d/iwRTjMsHHn78u2OGolmyVliPOEaG0R4QWWlkOKnqmvNU3UwPQkWirKtJ X-Received: by 2002:a7b:c8c3:: with SMTP id f3mr29464759wml.30.1632143805737; Mon, 20 Sep 2021 06:16:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632143805; cv=none; d=google.com; s=arc-20160816; b=blF28zhZJ1M98AW6aaB8ucc8LKfnLQ8JDS2z56segPXZ0ZxIC+d+sNEGNVhfq4Xm2O 0S1aMx9HWnIlzy3U5a0JsGqNnPbesqudxO0RIju7X6Agax5L+jKifgysUjOBfYBGMBxN VTKkowkiT90wD5uE6OodwqSqTZk0NgXd0G7QqC4oZfAN8nz9tUTAprc/weMRQLxN9ZAa z9xwIAhV+QXsNf+iLoEwc3m2ertdRSMqQM5RAE3NKh8Sp1jv04TRQP2Mw5vLmSIm4YuK DL87F2m8kVYIl2eaymvn9xcibwJ9IMCJWoK/5ctGTGpCUzTzoAFdKjSFVwkm+HyrzFVp 03cw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=ofSEfNtbm8m+fv38nBoWw8Tm+zk/GAHkwh0E6Qi14Hw=; b=k1eIQee4RyWF7pLJF95cSRbNDaj7laHeRuZwbvrUw4PM+nMeDGRAAtUBI5HZBnVMQk 4MvsaZ51VpfkRVwfuXQ7Hfw28449v3ml3XEgpETmY9wLKAj5bvWGeAbog9iJ9pG0ct7k mWP3AZW2/UpUMcFe+inGlZiR7BCYWphWWX/fkXBgF+Pokm6tvCM74m67MhkOg+d8Gnwd rHFWRKoDYxWm/ffgeyrRoZfJe5PrJSArRNLZo3nyU43sQJfW7AhX7HDs/in7d9XYV/SH Fw23SMRU+F5K7fUF7RwlgvgltSf09Q7NcFqjLwwUWcpO4WfRnNmsWGVAlxUsS2kBpsfl CQCg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bi7si6499499edb.451.2021.09.20.06.15.45; Mon, 20 Sep 2021 06:16:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234318AbhITI4R (ORCPT + 99 others); Mon, 20 Sep 2021 04:56:17 -0400 Received: from outbound-smtp22.blacknight.com ([81.17.249.190]:47093 "EHLO outbound-smtp22.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229844AbhITI4P (ORCPT ); Mon, 20 Sep 2021 04:56:15 -0400 Received: from mail.blacknight.com (pemlinmail02.blacknight.ie [81.17.254.11]) by outbound-smtp22.blacknight.com (Postfix) with ESMTPS id A26D2BB42B for ; Mon, 20 Sep 2021 09:54:47 +0100 (IST) Received: (qmail 26556 invoked from network); 20 Sep 2021 08:54:47 -0000 Received: from unknown (HELO stampy.112glenside.lan) (mgorman@techsingularity.net@[84.203.17.29]) by 81.17.254.9 with ESMTPA; 20 Sep 2021 08:54:47 -0000 From: Mel Gorman To: Linux-MM Cc: NeilBrown , Theodore Ts'o , Andreas Dilger , "Darrick J . Wong" , Matthew Wilcox , Michal Hocko , Dave Chinner , Rik van Riel , Vlastimil Babka , Johannes Weiner , Jonathan Corbet , Linux-fsdevel , LKML , Mel Gorman Subject: [RFC PATCH 0/5] Remove dependency on congestion_wait in mm/ Date: Mon, 20 Sep 2021 09:54:31 +0100 Message-Id: <20210920085436.20939-1-mgorman@techsingularity.net> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Cc list similar to "congestion_wait() and GFP_NOFAIL" as they're loosely related. This is a prototype series that removes all calls to congestion_wait in mm/ and deletes wait_iff_congested. It's not a clever implementation but congestion_wait has been broken for a long time (https://lore.kernel.org/linux-mm/45d8b7a6-8548-65f5-cccf-9f451d4ae3d4@kernel.dk/). Even if it worked, it was never a great idea. While excessive dirty/writeback pages at the tail of the LRU is one possibility that reclaim may be slow, there is also the problem of too many pages being isolated and reclaim failing for other reasons (elevated references, too many pages isolated, excessive LRU contention etc). This series replaces the reclaim conditions with event driven ones o If there are too many dirty/writeback pages, sleep until a timeout or enough pages get cleaned o If too many pages are isolated, sleep until enough isolated pages are either reclaimed or put back on the LRU o If no progress is being made, let direct reclaim tasks sleep until another task makes progress This has been lightly tested only and the testing was useless as the relevant code was not executed. The workload configurations I had that used to trigger these corner cases no longer work (yey?) and I'll need to implement a new synthetic workload. If someone is aware of a realistic workload that forces reclaim activity to the point where reclaim stalls then kindly share the details. -- 2.31.1 Mel Gorman (5): mm/vmscan: Throttle reclaim until some writeback completes if congested mm/vmscan: Throttle reclaim and compaction when too may pages are isolated mm/vmscan: Throttle reclaim when no progress is being made mm/writeback: Throttle based on page writeback instead of congestion mm/page_alloc: Remove the throttling logic from the page allocator include/linux/backing-dev.h | 1 - include/linux/mmzone.h | 12 ++++ include/trace/events/vmscan.h | 38 +++++++++++ include/trace/events/writeback.h | 7 -- mm/backing-dev.c | 48 -------------- mm/compaction.c | 2 +- mm/filemap.c | 1 + mm/internal.h | 11 ++++ mm/memcontrol.c | 10 +-- mm/page-writeback.c | 11 +++- mm/page_alloc.c | 26 ++------ mm/vmscan.c | 110 ++++++++++++++++++++++++++++--- mm/vmstat.c | 1 + 13 files changed, 180 insertions(+), 98 deletions(-) -- 2.31.1