[SERVER-81851] Constant-fold makeBsonObj Created: 04/Oct/23 Updated: 18/Jan/24 |
|
| Status: | Backlog |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Alya Berciu | Assignee: | Backlog - Query Optimization |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | M9 | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Assigned Teams: |
Query Optimization
|
||||||||
| Participants: | |||||||||
| Description |
|
Once FunctionCall("makeBsonObj", Constant [MakeObjSpec], Constant [anything], <any args that don't depend on any external variables>) And const-folds it into a Constant [<object>] according to the given MakeObjSpec (second argument). Note that the same logic can be used for makeObj as well. One idea would be to just execute this SBE expression once and set the output to the constant value. |