pgvector icon indicating copy to clipboard operation
pgvector copied to clipboard

Swap max costing values to align with upstream guidance

Open jkatz opened this issue 1 year ago • 1 comments

A feature targeted for PostgreSQL 18 (postgres/postgres@e2225346) that makes optimizations around disabled path nodes impacted pgvector such that PostgreSQL would choose to perform an index scan when it should have used a different scan (e.g. SELECT count(*) FROM table). Per upstream guidance[1], the recommendation is to switch to using get_float8_infinity(), which achieves the same behavior in backbranches, and can be adapated to work with the new behavior introduced in PostgreSQL 18.

[1] https://www.postgresql.org/message-id/2281822.1724441531%40sss.pgh.pa.us

jkatz avatar Aug 23 '24 21:08 jkatz

Thanks @jkatz, will merge once things are finalized.

ankane avatar Aug 23 '24 22:08 ankane

Looks like CI is still failing for pg18, but should be okay to merge. Thanks @jkatz!

ankane avatar Sep 20 '24 01:09 ankane

Pushed a different fix in 1291b12090bbb03bd92b92e42a1567ae5b1c96ad to address this.

ankane avatar Oct 22 '24 07:10 ankane