Re: Reducing memory consumed by RestrictInfo list translations in partitionwise join planning

From: Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>
To: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: Dmitry Dolgov <9erthalion6(at)gmail(dot)com>, tomas(at)vondra(dot)me, vignesh C <vignesh21(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Richard Guo <guofenglinux(at)gmail(dot)com>, David Rowley <dgrowleyml(at)gmail(dot)com>
Subject: Re: Reducing memory consumed by RestrictInfo list translations in partitionwise join planning
Date: 2025-02-20 11:58:48
Message-ID: CAExHW5t6NpGaif6ZO_P+L1cPZk27+Ye2LxfqRVXf0OiSsW9WSg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Feb 4, 2025 at 4:07 PM Ashutosh Bapat
<ashutosh(dot)bapat(dot)oss(at)gmail(dot)com> wrote:
>
> If we are not interested in saving memory, there is a simpler way to
> improve planning time by adding a hash table per equivalence class to
> store the derived clauses, instead of a linked list, when the number
> of derived clauses is higher than a threshold (say 32 same as the
> threshold for join_rel_list. Maybe that approach will yield stable
> planning time.
>

PFA patchset with conflict, with latest HEAD, resolved. I have dropped
0005 from the previous patchset since it didn't show any significant
performance difference. Other than these two things, the patchset is
same as the previous one.

--
Best Wishes,
Ashutosh Bapat

Attachment Content-Type Size
0001-RestrictInfo-hash-table-interface-20250220.patch text/x-patch 7.2 KB
0004-Avoid-translating-RestrictInfo-repeatedly-20250220.patch text/x-patch 14.6 KB
0003-Use-RestrictInfo-hash-table-for-storing-EC--20250220.patch text/x-patch 12.3 KB
0002-Compact-PlannerInfo-to-restore-its-previous-20250220.patch text/x-patch 1.9 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Shlok Kyal 2025-02-20 12:14:36 Re: Proposal: Filter irrelevant change before reassemble transactions during logical decoding
Previous Message Amit Kapila 2025-02-20 11:31:33 Re: ReplicationSlotRelease() crashes when the instance is in the single user mode