Re: pgsql: Improve nbtree skip scan primitive scan scheduling.

From: Peter Geoghegan <pg(at)bowt(dot)ie>
To: Mark Dilger <mark(dot)dilger(at)enterprisedb(dot)com>
Cc: Matthias van de Meent <boekewurm+postgres(at)gmail(dot)com>, pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Improve nbtree skip scan primitive scan scheduling.
Date: 2025-04-27 03:53:08
Message-ID: CAH2-Wz=1eJZMSMoACDW2oLcxd8QUtKQS7HuYtqx98LLji+WKuQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

On Sat, Apr 26, 2025 at 10:39 PM Mark Dilger
<mark(dot)dilger(at)enterprisedb(dot)com> wrote:
> Peter, Matthias, thanks kindly for the good work on skipscans!

Thanks!

> I found a test case which fails after commit 21a152b37f36c9563d1b0b058fe1436baf578b4c. Please find a reproducible test case, attached.

The bug isn't actually in commit
21a152b37f36c9563d1b0b058fe1436baf578b4c -- it's just an accident that
the mechanism added by that commit happens to make your test case
fail. The underlying issue was introduced in commit 8a510275, "Further
optimize nbtree search scan key comparisons".

This looks to have been a silly oversight in our handling of NULL
tuple datums within _bt_check_compare. Attached provisional fix makes
your test case pass.

--
Peter Geoghegan

Attachment Content-Type Size
v1-0001-Provisional-fix.patch application/octet-stream 849 bytes

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Bertrand Drouvot 2025-04-27 08:25:53 Re: clang-tidy complaints
Previous Message Mark Dilger 2025-04-27 02:38:51 Re: pgsql: Improve nbtree skip scan primitive scan scheduling.