postgresql/src
Peter Geoghegan 480bc6e3ed Remove unneeded nbtree array preprocessing assert.
Certain cases involving the use of cursors had assertion failures within
_bt_preprocess_keys's recently added no-op return path.  The assertion
in question made the faulty assumption that a second or third call to
_bt_preprocess_keys (within the same btrescan) could only happen when
another scheduled primitive index scan was just about to begin.

It would be possible to address the problem by only allowing scans that
have array keys to take the new no-op path, forcing affected cases to
perform redundant preprocessing work.  It seems simpler to just remove
the assertion, and reframe the no-op path as a more general mechanism.
Take this simpler approach.

The important underlying principle is that we only need to perform
preprocessing once per btrescan (at most).  This is expected regardless
of whether or not the scan happens to have array keys.

Oversight in commit 1b134ca5, which enhanced nbtree ScalarArrayOp
execution.

Reported-By: Alexander Lakhin <exclusion@gmail.com>
Discussion: https://postgr.es/m/ef0f7c8b-a6fa-362e-6fd6-054950f947ca@gmail.com
2024-04-22 13:58:06 -04:00
..
backend Remove unneeded nbtree array preprocessing assert. 2024-04-22 13:58:06 -04:00
bin Fix dumps of partitioned tables with table AMs 2024-04-22 15:15:36 +09:00
common Update src/common/unicode/.gitignore 2024-04-22 09:16:33 +02:00
fe_utils Allow dbname to be written as part of connstring via pg_basebackup's -R option. 2024-03-21 10:50:33 +05:30
include Remove resowner_private.h 2024-04-20 18:01:03 +09:00
interfaces Fix incorrect parameter name in prototype 2024-04-19 09:58:00 +02:00
makefiles Optimize pg_popcount() with AVX-512 instructions. 2024-04-06 21:56:23 -05:00
pl Fix plpgsql's handling of -- comments following expressions. 2024-04-10 15:45:58 -04:00
port Optimize visibilitymap_count() with AVX-512 instructions. 2024-04-06 22:58:23 -05:00
template Remove AIX support 2024-02-28 15:17:23 +04:00
test Revert recent ill-advised test case changes. 2024-04-19 17:21:56 -04:00
timezone Update time zone data files to tzdata release 2024a. 2024-02-01 15:57:53 -05:00
tools Update src/tools/pginclude/README to match recent changes to cpluspluscheck 2024-04-18 11:37:01 +02:00
tutorial Update copyright for 2024 2024-01-03 20:49:05 -05:00
.gitignore
DEVELOPERS
Makefile Remove distprep 2023-11-06 15:18:04 +01:00
Makefile.global.in Update Unicode data to CLDR 45 2024-04-22 09:16:33 +02:00
Makefile.shlib Remove AIX support 2024-02-28 15:17:23 +04:00
meson.build Update copyright for 2024 2024-01-03 20:49:05 -05:00
nls-global.mk Remove distprep 2023-11-06 15:18:04 +01:00