Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m6atM-0002rh-2e for pgsql-performance@arkaria.postgresql.org; Thu, 22 Jul 2021 15:45:44 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1m6asp-00019Y-1d for pgsql-performance@arkaria.postgresql.org; Thu, 22 Jul 2021 15:45:11 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m6aso-00019P-PZ for pgsql-performance@lists.postgresql.org; Thu, 22 Jul 2021 15:45:10 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m6asm-0000dA-Gp for pgsql-performance@postgresql.org; Thu, 22 Jul 2021 15:45:10 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 16MFj2Q2784577; Thu, 22 Jul 2021 11:45:02 -0400 From: Tom Lane To: "ldh@laurent-hasson.com" cc: David Rowley , Peter Geoghegan , Justin Pryzby , "pgsql-performance@postgresql.org" Subject: Re: Big performance slowdown from 11.2 to 13.3 In-reply-to: References: <20210721191528.GC19620@telsasoft.com> <732758.1626911007@sss.pgh.pa.us> Comments: In-reply-to "ldh@laurent-hasson.com" message dated "Thu, 22 Jul 2021 15:00:33 -0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <784575.1626968702.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Thu, 22 Jul 2021 11:45:02 -0400 Message-ID: <784576.1626968702@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk "ldh@laurent-hasson.com" writes: > So, I went possibly nuclear, and still no cigar. Something's not right. > - hash_mem_multiplier =3D '10' > - work_mem =3D '1GB' > The results are > Batches: 5 Memory Usage: 2,449,457kB Disk Usage: 105,936kB > Execution Time: 1,837,126.766 ms > It's still spilling to disk and seems to cap at 2.5GB of memory usage in= spite of configuration. That is ... weird. Maybe you have found a bug in the spill-to-disk logic; it's quite new after all. Can you extract a self-contained test case that behaves this way? regards, tom lane