Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vzuKP-001QmE-31 for pgsql-hackers@arkaria.postgresql.org; Tue, 10 Mar 2026 10:28:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vzuKO-002ZBN-0E for pgsql-hackers@arkaria.postgresql.org; Tue, 10 Mar 2026 10:28:40 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1vzuKN-002ZBF-0Z for pgsql-hackers@lists.postgresql.org; Tue, 10 Mar 2026 10:28:40 +0000 Received: from fout-b7-smtp.messagingengine.com ([202.12.124.150]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1vzuKK-00000001Qxd-2Xl5 for pgsql-hackers@lists.postgresql.org; Tue, 10 Mar 2026 10:28:38 +0000 Received: from phl-compute-09.internal (phl-compute-09.internal [10.202.2.49]) by mailfout.stl.internal (Postfix) with ESMTP id 1F0AC1D00190; Tue, 10 Mar 2026 06:28:35 -0400 (EDT) Received: from phl-frontend-03 ([10.202.2.162]) by phl-compute-09.internal (MEProxy); Tue, 10 Mar 2026 06:28:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm1; t=1773138514; x=1773224914; bh=WTdKZRkVNT UxiVrPFAy6ZX/iLp+NOQM/DGNDrDffKg0=; b=l4Ag20BeS8zbaFZsd6n75lOpL4 98fPrhTIeSjLzqRXC0v7WBZFA+aC2gbas6OFJbEs7Ygx8gQ07V3sggBVRdYdlSbj i/jJqJwLJK+EW1paFvA2ffnPk6hXz16sWQdroVibocM2n0geW/Sp1VqZbv135Xpe 1xmOrZL8kW3DiQQbfodkxbpviN3o3SNPorYWKz3axLdp8WcyiyOSPYI4qYAggUSi HqYXFtA4V5aSlhc5IcKUJuJTYlLwUVL4i1fAEPbPr5hEARF52R3f+YTC37bh0XcJ tA7Dy8bhTOEGzxKJCnuW12t/Y4odg5ssWIJKkaSgyFKLDen9vbmRQt7+xKQw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1773138514; x=1773224914; bh=WTdKZRkVNTUxiVrPFAy6ZX/iLp+NOQM/DGN DrDffKg0=; b=O4UsXx4m7h8AyUhcv2N6HtB0W2YHkFvMcrQlwczqTay1XuFnzdE Ooyf0CH1IkC6tzyLBdqBrRxdChse2H+Be7CmfNtqEb+L0K12TlQpF4++IKwS9kdl VfqJ7OkyqTCeMR2AocV8WpXnHMow6MCuV03RkoCL+Be4Mpg/Q5eWz0Wff2l8By1b VjNqlLtoKYQa9UrQspAhoYSbLxcuo/WkwZbEk5iAOqadQ7QHVgX85/a4L7FTWuTk LJqs0O256oNs2s41NYCrk/BsWCwkHe1AZWmtwvBQI9M21/fYEB88EUukJkKnPCqC WpJ4eaNdHsLcqd/o67CjKMUeOu4VYd6RZUw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgddvkedtkeefucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnegfrh hlucfvnfffucdljedtmdenucfjughrpeffhffvvefukfhfgggtuggjsehgtderredttdej necuhfhrohhmpefoihgthhgrvghlucfrrghquhhivghruceomhhitghhrggvlhesphgrqh huihgvrhdrgiihiieqnecuggftrfgrthhtvghrnhepveetjefgjeevgedukeehieeuieeu ieevueeiudegheevuefggfduueelgeelieetnecuvehluhhsthgvrhfuihiivgeptdenuc frrghrrghmpehmrghilhhfrhhomhepmhhitghhrggvlhesphgrqhhuihgvrhdrgiihiidp nhgspghrtghpthhtohepfedpmhhouggvpehsmhhtphhouhhtpdhrtghpthhtohepgihunh gvnhhgiihhohhusehgmhgrihhlrdgtohhmpdhrtghpthhtohepphhgshhqlhdqhhgrtghk vghrsheslhhishhtshdrphhoshhtghhrvghsqhhlrdhorhhgpdhrtghpthhtohepsgihrg hvuhiikedusehgmhgrihhlrdgtohhm X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 10 Mar 2026 06:28:33 -0400 (EDT) Date: Tue, 10 Mar 2026 19:28:29 +0900 From: Michael Paquier To: Xuneng Zhou Cc: pgsql-hackers , Nazir Bilal Yavuz Subject: Re: Streamify more code paths Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="c3Uu1kzScN6MTVPa" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --c3Uu1kzScN6MTVPa Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Mar 10, 2026 at 02:06:12PM +0800, Xuneng Zhou wrote: > Here=E2=80=99s v5 of the patchset. The wal_logging_large patch has been > removed, as no performance gains were observed in the benchmark runs. Looking at the numbers you are posting, it is harder to get excited about the hash, gin, bloom_vacuum and wal_logging. The worker method seems more efficient, may show that we are out of noise level. The results associated to pgstattuple and the bloom scans are on a different level for the three methods. Saying that, it is really nice that you have sent the benchmark. The measurement method looks in line with the goal here after review (IO stats, calculations), and I have taken some time to run it to get an idea of the difference for these five code paths, as of (slightly edited the script for my own environment, result is the same): =2E/run_streaming_benchmark --baseline --io-method=3Dio_uring/worker I am not much interested in the sync case, so I have tested the two other methods: 1) method=3DIO-uring bloom_scan_large base=3D 725.3ms patch=3D 99.9ms 7.26x ( 86.2%) (reads=3D19676->1294, io_time=3D688.36->33.69ms) bloom_vacuum_large base=3D 7414.9ms patch=3D 7455.2ms 0.99x ( -0.5%) (reads=3D48361->11597, io_time=3D459.02->257.51ms) pgstattuple_large base=3D 12642.9ms patch=3D 11873.5ms 1.06x ( 6.1%) (reads=3D206945->12983, io_time=3D6516.70->143.46ms) gin_vacuum_large base=3D 3546.8ms patch=3D 2317.9ms 1.53x ( 34.6%) (reads=3D20734->17735, io_time=3D3244.40->2021.53ms) hash_vacuum_large base=3D 12268.5ms patch=3D 11751.1ms 1.04x ( 4.2%) (reads=3D76677->15606, io_time=3D1483.10->315.03ms) wal_logging_large base=3D 33713.0ms patch=3D 32773.9ms 1.03x ( 2.8%) (reads=3D21641->21641, io_time=3D81.18->77.25ms) 2) method=3Dworker io-workers=3D3 bloom_scan_large base=3D 725.0ms patch=3D 465.7ms 1.56x ( 35.8%) (reads=3D19676->1294, io_time=3D688.70->52.20ms) bloom_vacuum_large base=3D 7138.3ms patch=3D 7156.0ms 1.00x ( -0.2%) (reads=3D48361->11597, io_time=3D284.56->64.37ms) pgstattuple_large base=3D 12429.3ms patch=3D 11916.8ms 1.04x ( 4.1%) (reads=3D206945->12983, io_time=3D6501.91->32.24ms) gin_vacuum_large base=3D 3769.4ms patch=3D 3716.7ms 1.01x ( 1.4%) (reads=3D20775->17684, io_time=3D3562.21->3528.14ms) hash_vacuum_large base=3D 11750.1ms patch=3D 11289.0ms 1.04x ( 3.9%) (reads=3D76677->15606, io_time=3D1296.03->98.72ms) wal_logging_large base=3D 32862.3ms patch=3D 33179.7ms 0.99x ( -1.0%) (reads=3D21641->21641, io_time=3D91.42->90.59ms)=20 The bloom scan case is a winner in runtime for both cases, and in terms of stats we get much better numbers for all of them. These feel rather in line with what you have, except for pgstattuple's runtime, still its IO numbers feel good. That's just to say that I'll review them and try to do something about at least some of the pieces for this release. -- Michael --c3Uu1kzScN6MTVPa Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmmv8k0ACgkQnvQgOdby QH2X1A/+O9R1MW/3GvDIJoqRphd12J4tn1n31CO5+YeE3TruvZhiTDuiwhKr50ee rO2itCrDijS6n5YMTHfZ4MwgkX9sZwLBlGMf3+GlYp0zP5spV1fwlBamUp02proV 4EhyvutUYQuDBMjOODfe8S4zJ3qkRf9kgIu664/GU56EgmV8e7NdPouXyRf/rqdQ h9CJmpuR5hi0OwksX+OYgiv+MjYsdR+/EahcYua9AvnVQzpVhMTOjVD6+DYE3pxX qeppq/FB7TGGZJfqUOfMPsuT/qdxsz+9H6NmzkfMuJ3YNouY+hSQdgv/VCowL7UM kiUnbpYDVQuQsHKqF32pCcKSkXMdFX9LTt68u0e+LfUMADF1F8L8pRA5Ga2X1GIv kFEwYL87WD8UrwDUJweSTfwR3N8n2nm4PdT1AjrxQml47HB+/ItXSt6KFKHIH9za 22SRAFKZkg9vLfiWHB3tqguwpKDXqD98gBDxJzr7YoW3VTNm5ubgfESCsUGRKIom nZyXmfC+7uXWgMxWtb8IGFcGav+P0DlrSGAhuZhm9oQqT7ShjWTCCO8nvWSLKm+f CKoNiBeHjqr33isaXTy+lg8YH8bkMr6mqBF4oak1nfPO/uiGmsm9640BEDuX5QNt hBRzeYHONTAC2OiPERVqxCYZGr+uf3pXj5T09DXcAlAjTVhgPPE= =5Iul -----END PGP SIGNATURE----- --c3Uu1kzScN6MTVPa--