[SERVER-80730] [CQF] Reduce optimization phases for sampling queries Created: 05/Sep/23  Updated: 29/Oct/23  Resolved: 26/Sep/23

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 7.2.0-rc0

Type: Improvement Priority: Major - P3
Reporter: Svilen Mihaylov (Inactive) Assignee: Chi-I Huang
Resolution: Fixed Votes: 0
Labels: M1, auto-reverted
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-79095 Reduce calls to VariableEnvironment::... Closed
Backwards Compatibility: Fully Compatible
Sprint: QO 2023-09-18, QO 2023-10-02
Participants:

 Description   

There are a few optimization phases that can be reduced for sampling queries. For example, ConstEval, PathFuse and MemoExploration. This also allows us to skip rebuilding reference trackers from those phases.



 Comments   
Comment by Githook User [ 26/Sep/23 ]

Author:

{'name': 'Chi-I Huang', 'email': 'chii.huang@mongodb.com', 'username': 'chiihuang'}

Message: SERVER-80730 Add OptPhase::SamplingConstEval and disable optimization phases for sampling

SamplingConstEval for now only does beta reduction for LambdaApplication. This allows ABTs to be successfully lowered without going through ConstEvalPost phase.

Disable ConstEvalPre, PathFuse, ConstEvalPost and MemoExploration for sampling estimator to avoid rebuilding reference tracker.
Branch: master
https://github.com/mongodb/mongo/commit/6eab6b668eacb980d905364353c335b228ae7f16

Comment by xgen-buildbaron-user [ 24/Sep/23 ]

Ticket re-opened due to revert. concurrency_sharded_causal_consistency_and_balancer began a consistent failure of jstests/concurrency/fsm_workloads/view_catalog_cycle_lookup.js

Comment by Githook User [ 24/Sep/23 ]

Author:

{'name': 'auto-revert-processor', 'email': 'dev-prod-dag@mongodb.com', 'username': ''}

Message: Revert "SERVER-80730 Add OptPhase::SamplingConstEval and disable optimization phases for sampling"

This reverts commit 63273d321ad6a4671f2e305ceccf1da2d1be5994.
Branch: master
https://github.com/mongodb/mongo/commit/65106a6f95168428eb14f6b09b7ba8954146e409

Comment by Githook User [ 23/Sep/23 ]

Author:

{'name': 'Chi-I Huang', 'email': 'chii.huang@mongodb.com', 'username': 'chiihuang'}

Message: SERVER-80730 Add OptPhase::SamplingConstEval and disable optimization phases for sampling

SamplingConstEval for now only does beta reduction for LambdaApplication. This allows ABTs to be successfully lowered without going through ConstEvalPost phase.

Disable ConstEvalPre, PathFuse, ConstEvalPost and MemoExploration for sampling estimator to avoid rebuilding reference tracker.
Branch: master
https://github.com/mongodb/mongo/commit/63273d321ad6a4671f2e305ceccf1da2d1be5994

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