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 1vn4WI-0022zR-1j for pgsql-hackers@arkaria.postgresql.org; Tue, 03 Feb 2026 00:43:54 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vn4VI-002H3l-1R for pgsql-hackers@arkaria.postgresql.org; Tue, 03 Feb 2026 00:42:52 +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 1vn4VH-002H3N-2K for pgsql-hackers@lists.postgresql.org; Tue, 03 Feb 2026 00:42:51 +0000 Received: from fout-b6-smtp.messagingengine.com ([202.12.124.149]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1vn4VE-00000000GZj-3Smc for pgsql-hackers@postgresql.org; Tue, 03 Feb 2026 00:42:50 +0000 Received: from phl-compute-06.internal (phl-compute-06.internal [10.202.2.46]) by mailfout.stl.internal (Postfix) with ESMTP id 420621D00085; Mon, 2 Feb 2026 19:42:47 -0500 (EST) Received: from phl-imap-05 ([10.202.2.95]) by phl-compute-06.internal (MEProxy); Mon, 02 Feb 2026 19:42:47 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eulerto.com; h= cc:cc:content-transfer-encoding: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=1770079367; x=1770165767; bh=g4ayhgIJSDlBxEwDfISrIcZddadZ/icxYPnLccijkbo=; b= g8/0MvtbC5PKgIuU5VQYLpLulmDjMhkOUdwcWirg2KrBbLs0W+CsGwS8O+suC0Q7 g+CXgGYCQT90rnzj4OmHMIX35wCFme29UGEjK0ikux8UuuX3ju6WXatXXsn1XquF f4Pj9aZtDyzIllkqAZYM4K34tiWbu0Jr6QgNhPDQORIg6DsUzbKhUwi3x20kJw2F Epb844uuS4YK07DLSJ2grtNOI2lXhjbQC2rFcvANakZRW/mjzcsSj2g0SyJttlf6 vwYZB6td4EvLfojMVms5NHY16hXXcKNAdZfxXfN86ULs2CKuzMe5aKnCHKWV+efW lYzAMjfzIYR+5UsmGm9KjQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :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=fm3; t=1770079367; x= 1770165767; bh=g4ayhgIJSDlBxEwDfISrIcZddadZ/icxYPnLccijkbo=; b=Z jBItYcO7zuJt62QqB521zeaNWi08fPCi4QDQ4gSt3ZZjrmPyKQlbrzYtp7Nq4pN9 GeZpR4S/dJMBkwVtnvvoq8y3fFbnccRlhApCqOobR+J8n4/ibGuiJxXxTcCUN+kW LcIkW9J/mcvEDvMSRaMb+Rnbf4VFWocn18lSUrYvJFL/Ht2hzqqflnQ6uY102DWt GNxdnRNYWbC8mXD9N5+xD+T68/D32Xw1SxsaxfYUrKLpF0n75qQcyGSchlYtWaxL v8Kuw+fZ5HPB0525z/oGiTHliU3OgTXAFCgm+pSvojGE85hrQY/NdwY1jmrZewKZ 8ENeRy9KpOfqtFB4+Rm8g== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgddujeeludduucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujf gurhepofggfffhvfevkfgjfhfutgfgsehtjeertdertddtnecuhfhrohhmpedfgfhulhgv rhcuvfgrvhgvihhrrgdfuceovghulhgvrhesvghulhgvrhhtohdrtghomheqnecuggftrf grthhtvghrnhephedvhfdufefhiedvudevgedvleeiheejteejhefhfeekieetuddvgfev ffdtjeeknecuffhomhgrihhnpehsthgrtghkvgigtghhrghnghgvrdgtohhmpdhpohhsth hgrhgvshhqlhdrohhrghdpvghnthgvrhhprhhishgvuggsrdgtohhmnecuvehluhhsthgv rhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepvghulhgvrhesvghulhgvrh htohdrtghomhdpnhgspghrtghpthhtohepledpmhhouggvpehsmhhtphhouhhtpdhrtghp thhtoheprghnthhhohhnihhnrdgsohhnnhgvfhhohiesuggrthgrughoghhhqhdrtghomh dprhgtphhtthhopehmhihonhesuggvsghirghnrdhorhhgpdhrtghpthhtohepmhgsrghn tghksehgmhigrdhnvghtpdhrtghpthhtohepphhoshhtghhrvghssehjvghlthgvfhdrnh hlpdhrtghpthhtoheprghlvhhhvghrrhgvsehkuhhrihhlvghmuhdruggvpdhrtghpthht ohepphhgshhqlhdqhhgrtghkvghrsheslhhishhtshdrphhoshhtghhrvghsqhhlrdhorh hgpdhrtghpthhtohepphdrphhsqhhlsehpihhnrghrrghfrdhinhhfohdprhgtphhtthho pehpghhsqhhlqdhhrggtkhgvrhhssehpohhsthhgrhgvshhqlhdrohhrghdprhgtphhtth hopegrnhgurhgvrghssehprhhogigvlhdrshgv X-ME-Proxy: Feedback-ID: i0c21471d:Fastmail Received: by mailuser.phl.internal (Postfix, from userid 501) id 0E073182007A; Mon, 2 Feb 2026 19:42:46 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface MIME-Version: 1.0 X-ThreadId: AykUuAdM-0ok Date: Mon, 02 Feb 2026 21:42:25 -0300 From: "Euler Taveira" To: "Jelte Fennema" , "Pierre Ducroquet" Cc: =?UTF-8?Q?=C3=81lvaro_Herrera?= , "PostgreSQL Hackers" , "Andreas Karlsson" , "Anthonin Bonnefoy" , pgsql-hackers , "Michael Banck" , "Christoph Berg" Message-Id: <56a7e683-434f-4d2d-a7ed-9ddefcf426f4@app.fastmail.com> In-Reply-To: References: Subject: Re: Change default of jit to off Content-Type: text/plain Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Fri, Jan 30, 2026, at 8:28 AM, Jelte Fennema-Nio wrote: > > +1 on disabling jit by default. At the FOSDEM Postgres developer meeting > consensus was hugely in favor of changing the default. So attached is a > trivial patch that does this. > As someone that analyzed dozens of cases that JIT performs poorly, I would say +1. However, I don't think it is a good idea. JIT was introduced in v11 (defaults to off) and the default was changed to on for v12. As Jeff said [1] I also think it was premature. It's been 7 years that JIT is enabled by default and changing this parameter could surprise users who use JIT to mainly improve runtime from OLAP queries. You can argue that the majority of the workloads are not composed by analytic queries. Fine. That's not an excuse to perform poorly with a small percentage of these analytic queries. Will you propose enabling it again after fixing the majority of these performance reports? That will be another source of confusion. Since there are some reports exposing these issues and articles discussing it, I would suggest improving the documentation stating that there are issues in this area and that they will be resolved in the future. (The documentation already stated the common issue -- short queries -- in the first paragraph [2]. Maybe we need to be more incisive.) Instead, of using the argument that JIT hurts short queries, I would like to see other alternative solutions for this JIT issue. The v15 added some columns to pg_stat_statements that helps us understand if JIT is hurting your queries. I don't have numbers but instead of turning JIT off we should adopt a less invasive solution like increasing the thresholds that triggers it -- jit_*_above_cost (probably using some pg_stat_statements reports). It is not a definitive fix, JIT needs improvement and an idea like making JIT more granular [3] could restore confidence in it. Maybe I'm being too optimistic but this is a similar argument that kept optimizer hints out of core: hints can reduce the pace of planner improvements since fewer bad query plans are reported due to use of hints to force the optimal query plan. Although I don't have plans to hack on JIT code but reports may encourage a few developers to propose changes in this area. [1] https://dba.stackexchange.com/a/264969 [2] https://www.postgresql.org/docs/current/jit-decision.html [3] https://www.postgresql.org/message-id/CAApHDvoq5VhV%3D2euyjgBN2bC8Bds9Dtr0bG7R%3DreeefJWKJRXA%40mail.gmail.com -- Euler Taveira EDB https://www.enterprisedb.com/