| From: | Melanie Plageman <melanieplageman(at)gmail(dot)com> |
|---|---|
| To: | Xuneng Zhou <xunengzhou(at)gmail(dot)com> |
| Cc: | Induja Sreekanthan <indujas(at)google(dot)com>, pgsql-hackers(at)postgresql(dot)org, Andres Freund <andres(at)anarazel(dot)de>, Simhachala Sasikanth Gottapu <simhachala(at)google(dot)com>, Vishal Bagga <vishalbagga(at)google(dot)com>, Madhukar <madhukarprasad(at)google(dot)com>, Shihao Zhong <shihaozhong(at)google(dot)com>, Yi Ding <yidin(at)google(dot)com>, Hardik Singh Negi <hardiksnegi(at)google(dot)com> |
| Subject: | Re: BUG: ReadStream look-ahead exhausts local buffers when effective_io_concurrency>=64 |
| Date: | 2026-08-05 15:50:53 |
| Message-ID: | CAAKRu_ZjLj7pzGNqPm0dtG1dtdgJJKWz91L4BjafN4=uyEJvew@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Thu, Jul 23, 2026 at 11:07 AM Melanie Plageman
<melanieplageman(at)gmail(dot)com> wrote:
>
> On Thu, Jul 2, 2026 at 7:50 PM Xuneng Zhou <xunengzhou(at)gmail(dot)com> wrote:
> >
> > If that's the case, I'm wondering whether it makes sense to backpatch
> > this fix to 18. I tried to do this for the local tree and the
> > reproducer passed. That said, it might not be safe to do so for a
> > stable version. It would be helpful to hear Melanie's and Andres's
> > thoughts on this.
>
> da6874635db fixes the originally reported bug in this thread on 18. It
> makes sense to backpatch it to 18. I hadn't thought of the TOAST case.
> I'm thinking about whether backpatching to 17 makes sense or not. It
> would be much more difficult to hit an issue in 17, but I'll need to
> think more about it.
I've backpatched the fix to pg 18. After some analysis, it seems we
can not hit the issue with any non-contrived example in 17 because in
practice sequential scans won't bump the lookahead distance past
io_combine_limit which can't exceed the minimum temp_buffers value.
There may be some contrived way to hit it with analyze but it seems
far-fetched. Also on 17, it's not a clean cherry-pick because we don't
have GetAdditionalLocalPinLimit(), and there seem to be more
implications to changing LimitAdditionalLocalPins(). So, for now,
let's just patch 18.
- Melanie
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Melanie Plageman | 2026-08-05 15:52:39 | Re: BUG: ReadStream look-ahead exhausts local buffers when effective_io_concurrency>=64 |
| Previous Message | Peter Eisentraut | 2026-08-05 15:47:32 | Re: Fix hashchar() and hashcharextended() to not depend on char signedness |