Re: Memory leak on subquery as scalar operand

From: Daniel Gustafsson <daniel(at)yesql(dot)se>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, David Rowley <dgrowleyml(at)gmail(dot)com>, lauri(dot)laanmets(at)eesti(dot)ee, pgsql-bugs <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: Memory leak on subquery as scalar operand
Date: 2023-05-16 13:31:42
Message-ID: BFDB5D98-EB13-444B-9BCE-B4880637B68B@yesql.se
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

> On 2 May 2023, at 15:33, Daniel Gustafsson <daniel(at)yesql(dot)se> wrote:

> The attached 0005 is a WIP attempt to address a few of the FIXME's in this
> patchset on top of your the 0001-0004.

I've attached a rebased v5 which has the above fixes as well as a few smaller
ones missed in v4. Testing through the reports linked to from the open item
it's clear that while there is still a continuous rise in resident size, this
slows it down dramatically with the size levelling out which unpatched master
doesn't. Reducing LLVMJIT_LLVM_CONTEXT_REUSE_MAX back even further pushes the
levelling off further as well, making me wonder if this is something worth
using a GUC for given that we're stuck with the destructive LLVM linker for the
foreseeable future?

--
Daniel Gustafsson

Attachment Content-Type Size
v5-0005-Address-review-comments.patch application/octet-stream 7.4 KB
v5-0004-wip-llvmjit-Plug-memory-leak-when-performing-inli.patch application/octet-stream 7.4 KB
v5-0003-wip-llvmjit-Make-llvm_types_module-variable-stati.patch application/octet-stream 1.4 KB
v5-0002-wip-llvmjit-remove-unnecessary-types.patch application/octet-stream 1.3 KB
v5-0001-wip-llvmjit-Use-explicit-LLVMContextRef.patch application/octet-stream 23.4 KB

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2023-05-16 13:52:08 Re: BUG #17936: Memory Leak when OPERATOR FAMILY use LANGUAGE SQL function
Previous Message PG Bug reporting form 2023-05-16 13:16:43 BUG #17936: Memory Leak when OPERATOR FAMILY use LANGUAGE SQL function