| From: | Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com> |
|---|---|
| To: | Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> |
| Cc: | Baji Shaik <baji(dot)pgdev(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: Pass heap tuple counts to parallel vacuum as double |
| Date: | 2026-11-10 06:02:28 |
| Message-ID: | EDFE5832-4D04-40CD-8562-5D53DB28CB40@gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
> On Nov 10, 2026, at 09:46, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> wrote:
>
> On Mon, Nov 9, 2026 at 3:16 PM Baji Shaik <baji(dot)pgdev(at)gmail(dot)com> wrote:
>>
>> Hi,
>>
>> I noticed that parallel_vacuum_bulkdel_all_indexes() and
>> parallel_vacuum_cleanup_all_indexes() take the heap tuple count as long,
>> while lazy vacuum passes a double and vacuumparallel.c stores it as a
>> double in shared memory for the index AMs. Where long is 32 bits, as on
>> Windows, a table with more than about 2.1 billion tuples gets a wrong
>> num_heap_tuples only when its indexes are vacuumed in parallel. It's
>> rare in practice, but the serial path has no such limit.
>>
>> The attached patch changes the parameter to double.
>
> Thank you for the report. The change looks good to me. I’m going to
> push it to master only, barring objections. Although it’s an oversight
> in commit 8e1fae193864, it can’t be backpatched, since it changes the
> function signatures.
>
> Regards,
>
> --
> Masahiko Sawada
> Amazon Web Services: https://aws.amazon.com
>
The patch also looks good to me.
I wonder if we can still get this into 19, as it hasn’t been released yet. This may be our last chance to change these function signatures for 19.
Best regards,
--
Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Chao Li | 2026-11-10 06:22:36 | Re: Update comments in functions for statistics import in postgres_fdw.c |
| Previous Message | Joao Rito | 2026-11-10 05:43:28 | Re: walreceiver: stale hot_standby_feedback xmin on primary when wal_receiver_status_interval = 0 (PG16 and later) |