Re: Questions/Observations related to Gist vacuum
Amit Kapila <amit.kapila16@gmail.com>
From: Amit Kapila <amit.kapila16@gmail.com>
To: Dilip Kumar <dilipbalaut@gmail.com>
Cc: Heikki Linnakangas <hlinnaka@iki.fi>,
Andrey Borodin <x4mmm@yandex-team.ru>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2019-10-17T03:31:43Z
Lists: pgsql-hackers
Attachments
- 0001-Fix-memory-leak-introduced-in-commit-7df159a620.patch (application/octet-stream) patch 0001
On Wed, Oct 16, 2019 at 11:20 AM Dilip Kumar <dilipbalaut@gmail.com> wrote: > > On Tue, Oct 15, 2019 at 7:13 PM Heikki Linnakangas <hlinnaka@iki.fi> wrote: > > > > On 15/10/2019 09:37, Amit Kapila wrote: > > > While reviewing a parallel vacuum patch [1], we noticed a few things > > > about $SUBJECT implemented in commit - > > > 7df159a620b760e289f1795b13542ed1b3e13b87. > > > > > > 1. A new memory context GistBulkDeleteResult->page_set_context has > > > been introduced, but it doesn't seem to be used. > > > > Oops. internal_page_set and empty_leaf_set were supposed to be allocated > > in that memory context. As things stand, we leak them until end of > > vacuum, in a multi-pass vacuum. > > Here is a patch to fix this issue. > The patch looks good to me. I have slightly modified the comments and removed unnecessary initialization. Heikki, are you fine me committing and backpatching this to 12? Let me know if you have a different idea to fix. -- With Regards, Amit Kapila. EnterpriseDB: http://www.enterprisedb.com
Commits
-
Delete empty pages in each pass during GIST VACUUM.
- 4e514c6180fb 13.0 landed
-
Fix memory leak introduced in commit 7df159a620.
- 62f4dd3796da 12.1 landed
- 70a6c37d524c 13.0 landed
-
Delete empty pages during GiST VACUUM.
- 7df159a620b7 12.0 cited