From: | Ibrar Ahmed <ibrar(dot)ahmad(at)gmail(dot)com> |
---|---|
To: | "k(dot)jamison(at)fujitsu(dot)com" <k(dot)jamison(at)fujitsu(dot)com> |
Cc: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Robert Haas <robertmhaas(at)gmail(dot)com> |
Subject: | Re: VACUUM memory management |
Date: | 2020-01-28 18:36:24 |
Message-ID: | CALtqXTcxcHe2jaCD8SXKjx2NUCsceh4iwFJnRe1r=rejkUfYxw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jan 22, 2020 at 11:17 AM k(dot)jamison(at)fujitsu(dot)com <
k(dot)jamison(at)fujitsu(dot)com> wrote:
> Hi Ibrar,
>
>
>
> Are you still working on this patch?
>
> Currently the patch does not apply mainly because of
>
> recent commits for parallel vacuum have updated the files in this patch.
>
> Kindly rebase it and change the status to "Needs Review" after.
>
>
>
> Upon quick scan of another thread [1] mentioned above,
>
> I believe the people involved had consensus on the same direction
>
> of allocating mem in chunks, and dynamically alloc when
>
> needed. A point for discussion was the size of chunk allocation.
>
>
>
> After a brief look of your patch, there's a typo between
>
> declaration and definition of lazy_vacuum_page():
>
> arryindex --> arrindex
>
>
>
> static int lazy_vacuum_page(Relation onerel, BlockNumber blkno,
> Buffer buffer,
>
> -
> int tupindex, LVRelStats *vacrelstats, Buffer *vmbuffer);
>
> +
> int arryindex, int tupindex, LVRelStats *vacrelstats, Buffer *vmbuffer);
>
>
>
> static int
>
> lazy_vacuum_page(Relation onerel, BlockNumber blkno, Buffer buffer,
>
> - int tupindex, LVRelStats
> *vacrelstats, Buffer *vmbuffer)
>
> + int arrindex, int tupindex,
> LVRelStats *vacrelstats, Buffer *vmbuffer)
>
>
>
> Unnecessary change:
>
> - long maxtuples;
>
> - int vac_work_mem =
> IsAutoVacuumWorkerProcess() &&
>
> + long maxtuples;
>
> + int vac_work_mem = IsAutoVacuumWorkerProcess() &&
>
>
>
> Other typo:
>
> + * pg_bsearch() -- bsearch algorithem for two dimention array.
>
> algorithem --> algorithm
>
> dimention --> dimension
>
>
>
> I might have missed something more,
>
> but I'll continue reviewing after the rebased patch.
>
>
>
> Regards,
>
> Kirk Jamison
>
>
>
> [1]
> https://www.postgresql.org/message-id/flat/CAGTBQpbDCaR6vv9%3DscXzuT8fSbckf%3Da3NgZdWFWZbdVugVht6Q%40mail.gmail.com
>
Hi,
Yes, I am working on that. I will send the rebased and updated patch.
--
Ibrar Ahmed
From | Date | Subject | |
---|---|---|---|
Next Message | Mike Lissner | 2020-01-28 18:55:47 | [Patch]: Documentation of ALTER TABLE re column type changes on binary-coercible fields |
Previous Message | Tom Lane | 2020-01-28 18:32:26 | Re: making the backend's json parser work in frontend code |