summaryrefslogtreecommitdiff
path: root/src/backend/executor
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2010-10-10 23:19:50 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2010-10-10 23:19:50 -0400
commit220e45bf325b061b8dbd7451f87cedc07da61706 (patch)
tree6bf141d758bec35be203f876802f685a819b968a /src/backend/executor
parentb48b9cb3a46d80401b122fd10780e8c623983a26 (diff)
Improve the planner's simplification of NOT constructs.
This patch merges the responsibility for NOT-flattening into eval_const_expressions' processing. It wasn't done that way originally because prepqual.c is far older than eval_const_expressions. But putting this work into eval_const_expressions saves one pass over the qual trees, and in fact saves even more than that because we can exploit the knowledge that the subexpressions have already been recursively simplified. Doing it this way also lets us do it uniformly over all expressions, whereas prepqual.c formerly just did it at top level to save cycles. That should improve the planner's ability to recognize logically-equivalent constructs. While at it, also add the ability to fold a NOT into BooleanTest and NullTest constructs (the latter only for the scalar-datatype case). Per discussion of bug #5702.
Diffstat (limited to 'src/backend/executor')
0 files changed, 0 insertions, 0 deletions