Re: Fix overflow of nbatch

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com>
Cc: Vaibhav Jain <jainva(at)google(dot)com>, pgsql-hackers(at)postgresql(dot)org, Madhukar <madhukarprasad(at)google(dot)com>, Sangeetha Seshadri <sangsesh(at)google(dot)com>
Subject: Re: Fix overflow of nbatch
Date: 2025-09-22 23:35:54
Message-ID: CAApHDvoHV7ZaNCELQDN_GXh4YvGwkKNTZOfDhAMV5ZhDR-RmDw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, 23 Sept 2025 at 11:21, Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com> wrote:
> I guess that because earlier in the function, nbatch is always clamped with:
>
> nbatch = pg_nextpower2_32(Max(2, minbatch));

I don't follow which part of that line could be constituted as
clamping. Maybe you've confused Max with Min?

David

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message David Rowley 2025-09-23 00:02:42 Re: Fix overflow of nbatch
Previous Message Chao Li 2025-09-22 23:20:42 Re: Fix overflow of nbatch