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 6FC02C433FE for ; Wed, 26 Jan 2022 21:47:16 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D95086B0071; Wed, 26 Jan 2022 16:47:15 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id D1D1C6B0072; Wed, 26 Jan 2022 16:47:15 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B6F176B0073; Wed, 26 Jan 2022 16:47:15 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0173.hostedemail.com [216.40.44.173]) by kanga.kvack.org (Postfix) with ESMTP id A0D8D6B0071 for ; Wed, 26 Jan 2022 16:47:15 -0500 (EST) Received: from smtpin09.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 625F590F67 for ; Wed, 26 Jan 2022 21:47:15 +0000 (UTC) X-FDA: 79073774430.09.22F0D56 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by imf06.hostedemail.com (Postfix) with ESMTP id A9B5A180007 for ; Wed, 26 Jan 2022 21:47:14 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 97A952190B; Wed, 26 Jan 2022 21:47:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1643233633; h=from:from:reply-to: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; bh=wwCqNAVxFssHUfnlnuxxpwR9TPFlYyH2jf2XVNtnT3k=; b=XcJ6wQDzpBOy1x4jIYITW+mimSq+65AA2rIlCdcuhMUXo/A15G25KPOSfjCK3Fscw/oTrW tIgkdy0qS+Fnj00999XYRVyTsdVlVby1iDTlAmszREqXL3ERkxTsNLJrUrq/cGsY0iu1In Sp/PWuXgienf88BE1DEke01fQFkO/kk= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1643233633; h=from:from:reply-to: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; bh=wwCqNAVxFssHUfnlnuxxpwR9TPFlYyH2jf2XVNtnT3k=; b=xO4XOLlbII9EwZlT1utYvMefWEYLl2bGeLCig45Ic1ejhDhW7Cgi8MDcDb4NvHLWQ9dwzm JNGlGC6CMWvonwBw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 9649213E3C; Wed, 26 Jan 2022 21:47:10 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id 3lIhFF7B8WHAQwAAMHmgww (envelope-from ); Wed, 26 Jan 2022 21:47:10 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 From: "NeilBrown" To: "Christoph Hellwig" Cc: "Trond Myklebust" , "Anna Schumaker" , "Chuck Lever" , "Andrew Morton" , "Mel Gorman" , "Christoph Hellwig" , "David Howells" , linux-nfs@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 02/23] MM: extend block-plugging to cover all swap reads with read-ahead In-reply-to: References: <164299573337.26253.7538614611220034049.stgit@noble.brown>, <164299611274.26253.13900771841681128440.stgit@noble.brown>, Date: Thu, 27 Jan 2022 08:47:06 +1100 Message-id: <164323362698.5493.8309546969459514762@noble.neil.brown.name> X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: A9B5A180007 X-Rspam-User: nil Authentication-Results: imf06.hostedemail.com; dkim=pass header.d=suse.de header.s=susede2_rsa header.b=XcJ6wQDz; dkim=pass header.d=suse.de header.s=susede2_ed25519 header.b=xO4XOLlb; dmarc=pass (policy=none) header.from=suse.de; spf=pass (imf06.hostedemail.com: domain of neilb@suse.de designates 195.135.220.28 as permitted sender) smtp.mailfrom=neilb@suse.de X-Stat-Signature: p9iywsepcwk1ah46ooofbjkyi863k5ih X-HE-Tag: 1643233634-287481 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000001, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Mon, 24 Jan 2022, Christoph Hellwig wrote: > On Mon, Jan 24, 2022 at 02:48:32PM +1100, NeilBrown wrote: > > Code that does swap read-ahead uses blk_start_plug() and > > blk_finish_plug() to allow lower levels to combine multiple read-ahead > > pages into a single request, but calls blk_finish_plug() *before* > > submitting the original (non-ahead) read request. > > This missed an opportunity to combine read requests. > >=20 > > This patch moves the blk_finish_plug to *after* all the reads. > > This will likely combine the primary read with some of the "ahead" > > reads, and that may slightly increase the latency of that read, but it > > should more than make up for this by making more efficient use of the > > storage path. > >=20 > > The patch mostly makes the code look more consistent. Performance > > change is unlikely to be noticeable. >=20 > Looks good: >=20 > Reviewed-by: Christoph Hellwig Thanks. >=20 > > Fixes-no-auto-backport: 3fb5c298b04e ("swap: allow swap readahead to be m= erged") >=20 > Is this really a thing? Maybe it should be..... As I'm sure you guessed, I think it is valuable to record this connection between commits, but I don't like it hasty automatic backporting of patches where the (unknown) risk might exceed the (known) value. This is how I choose to state my displeasure. Thanks, NeilBrown