Skip to content

Commit

Permalink
Teach bitmap path generation about transforming OR-clauses to SAOP's
Browse files Browse the repository at this point in the history
When optimizer generates bitmap paths, it considers breaking OR-clause
arguments one-by-one.  But now, a group of similar OR-clauses can be
transformed into SAOP during index matching.  So, bitmap paths should
keep up.

This commit teaches bitmap paths generation machinery to group similar
OR-clauses into dedicated RestrictInfos.  Those RestrictInfos are considered
both to match index as a whole (as SAOP), or to match as a set of individual
OR-clause argument one-by-one (the old way).

Therefore, bitmap path generation will takes advantage of OR-clauses to SAOP's
transformation.  The old way of handling them is also considered.  So, there
shouldn't be planning regression.

Discussion: https://postgr.es/m/567ED6CA.2040504%40sigaev.ru
Reviewed-by: Alexander Korotkov <aekorotkov@gmail.com>
  • Loading branch information
akorotkov authored and pashkinelfe committed Nov 6, 2024
1 parent 7a4d7ca commit 39eacb9
Show file tree
Hide file tree
Showing 7 changed files with 671 additions and 106 deletions.
Loading

0 comments on commit 39eacb9

Please sign in to comment.