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

Method EvalCtx

bolt/expression/EvalCtx.cpp:53–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

51 acceptNullableChild) {}
52
53EvalCtx::EvalCtx(
54 core::ExecCtx* execCtx,
55 ExprSet* exprSet,
56 const RowVector* row,
57 const std::string& currentSplitStr,
58 const bool acceptNullableChild)
59 : execCtx_(execCtx),
60 exprSet_(exprSet),
61 row_(row),
62 cacheEnabled_(execCtx->exprEvalCacheEnabled()),
63 maxSharedSubexprResultsCached_(
64 execCtx->queryCtx()
65 ? execCtx->queryCtx()
66 ->queryConfig()
67 .maxSharedSubexprResultsCached()
68 : core::QueryConfig({}).maxSharedSubexprResultsCached()),
69 currentSplitStr_(currentSplitStr) {
70 // TODO Change the API to replace raw pointers with non-const references.
71 // Sanity check inputs to prevent crashes.
72 BOLT_CHECK_NOT_NULL(execCtx);
73 BOLT_CHECK_NOT_NULL(exprSet);
74 BOLT_CHECK_NOT_NULL(row);
75
76 inputFlatNoNulls_ = true;
77 for (const auto& child : row->children()) {
78 BOLT_CHECK(acceptNullableChild || child != nullptr);
79 if (acceptNullableChild && !child) {
80 continue;
81 }
82 if ((!child->isFlatEncoding() && !child->isConstantEncoding()) ||
83 child->mayHaveNulls()) {
84 inputFlatNoNulls_ = false;
85 }
86 }
87}
88
89EvalCtx::EvalCtx(core::ExecCtx* execCtx)
90 : execCtx_(execCtx),

Callers

nothing calls this directly

Calls 6

exprEvalCacheEnabledMethod · 0.80
queryCtxMethod · 0.80
QueryConfigClass · 0.50
childrenMethod · 0.45
mayHaveNullsMethod · 0.45

Tested by

no test coverage detected