MCPcopy Create free account
hub / github.com/bytedance/bolt / evalSimplified

Method evalSimplified

bolt/expression/Expr.cpp:480–508  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

478 }
479
480 // If the initial non null holder couldn't be created, start with the input
481 // `rows`.
482 auto* remainingRows = nonNullHolder.get() ? nonNullHolder.get() : &rows;
483
484 if (remainingRows->hasSelections()) {
485 evalSimplifiedImpl(*remainingRows, context, result);
486 }
487
488 if (!type()->isFunction()) {
489 addNulls(rows, remainingRows->asRange().bits(), context, result);
490 }
491}
492
493void Expr::releaseInputValues(EvalCtx& evalCtx) {
494 evalCtx.releaseVectors(inputValues_);
495 inputValues_.clear();
496}
497
498void Expr::evalSimplifiedImpl(
499 const SelectivityVector& rows,
500 EvalCtx& context,
501 VectorPtr& result) {
502 // Handle special form expressions.
503 if (isSpecialForm()) {
504 evalSpecialFormSimplified(rows, context, result);
505 return;
506 }
507
508 MutableRemainingRows remainingRows(rows, context);
509 const bool defaultNulls = vectorFunction_->isDefaultNullBehavior();
510 auto evalArg = [&](int32_t i) {
511 auto& inputValue = inputValues_[i];

Callers 4

evalSimplifiedImplMethod · 0.80
evalMethod · 0.80

Calls 7

checkOrSetEmptyResultFunction · 0.85
hasSelectionsMethod · 0.80
typeEnum · 0.50
poolMethod · 0.45
getMethod · 0.45
bitsMethod · 0.45
asRangeMethod · 0.45

Tested by

no test coverage detected