pgsql: Introduce optimized routine for linear searches of arrays

Поиск
Список
Период
Сортировка
От John Naylor
Тема pgsql: Introduce optimized routine for linear searches of arrays
Дата
Msg-id E1oLcit-0004Qs-68@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Introduce optimized routine for linear searches of arrays

Use SSE2 intrinsics to speed up the search, where available.  Otherwise,
use a simple 'for' loop.  The motivation to add this now is to speed up
XidInMVCCSnapshot(), which is the reason only unsigned 32-bit integer
arrays are optimized. Other types are left for future work, as is the
extension of this technique to non-x86 platforms.

Nathan Bossart

Reviewed by: Andres Freund, Bharath Rupireddy, Masahiko Sawada
Discussion: https://postgr.es/m/20220713170950.GA3116318%40nathanxps13

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/b6ef167564905e8dab8af1b1dba0997ec61204ca

Modified Files
--------------
src/include/port/pg_lfind.h                        | 103 +++++++++++++++++++++
src/test/modules/Makefile                          |   1 +
src/test/modules/test_lfind/.gitignore             |   4 +
src/test/modules/test_lfind/Makefile               |  23 +++++
.../modules/test_lfind/expected/test_lfind.out     |  12 +++
src/test/modules/test_lfind/sql/test_lfind.sql     |   8 ++
src/test/modules/test_lfind/test_lfind--1.0.sql    |   8 ++
src/test/modules/test_lfind/test_lfind.c           |  52 +++++++++++
src/test/modules/test_lfind/test_lfind.control     |   4 +
9 files changed, 215 insertions(+)


В списке pgsql-committers по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: pgsql: doc: mention that COPY MATCH requires columns _in_ _order_
Следующее
От: Peter Eisentraut
Дата:
Сообщение: pgsql: Remove unused short option from getopt_long() call