[SERVER-82350] Consider moving MatchExpressions instead of always cloning them Created: 20/Oct/23  Updated: 01/Nov/23

Status: Backlog
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Task Priority: Major - P3
Reporter: Alexander Ignatyev Assignee: Backlog - Query Optimization
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Issue split
split from SERVER-75079 Simplify boolean expressions before f... Closed
Assigned Teams:
Query Optimization
Participants:

 Description   

The Boolean simplifier always clones MatchExpressions when restoring expressions from their bitset representation. Given that once the simplified MatchExpression is materialized we drop the original one in favour of the simplified one, so we can avoid cloning/copying data, and moved it instead.
We should be careful here and remember that sometimes one node participates more than once in the expression.


Generated at Thu Feb 08 06:48:59 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.