-
Type:
Improvement
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Execution
-
Fully Compatible
-
QE 2025-07-21
-
200
-
None
-
3
-
TBD
-
None
-
None
-
None
-
None
-
None
-
None
-
None
After switching to the toolchain v5 as default in 341832a we've observed few performance regressions including a 10% regression in ElemMatchLargeMixedInAndOrWithDuplicates causing BF-37502.
It was determined that on AWS Graviton2 under the mentioned workload the branch misprediction rate increased ~2.5 times while the number of branches executed increased ~5%.
The improvement to ByteCode::getField() aims to reduce the number of branches executed and switch to static branch prediction by avoiding taking branches for presumably the most common execution scenario - when the input is a BSON object.
This change seems to reduce the run-time of the workload by ~2%.
- is related to
-
SERVER-104955 Optimization opportunity in mongo::sbe::vm::ByteCode::runInternal()
-
- Open
-