perf(expr): Add EvalCtx constructor with pre-computed inputFlatNoNulls flag (#17232)#17232
Closed
darxsys wants to merge 1 commit intofacebookincubator:mainfrom
Closed
perf(expr): Add EvalCtx constructor with pre-computed inputFlatNoNulls flag (#17232)#17232darxsys wants to merge 1 commit intofacebookincubator:mainfrom
darxsys wants to merge 1 commit intofacebookincubator:mainfrom
Conversation
✅ Deploy Preview for meta-velox canceled.
|
|
@darxsys has exported this pull request. If you are a Meta employee, you can view the originating Diff in D101418306. |
Build Impact AnalysisSelective Build Targets (building these covers all 396 affected)Total affected: 396/567 targets Affected targets (396)Directly changed (142)
Transitively affected (254)
Fast path • Graph from main@f1c6510ad978b913af37be3a775104e05479287d |
59f232c to
e45a320
Compare
darxsys
pushed a commit
to darxsys/velox
that referenced
this pull request
Apr 17, 2026
…bookincubator#17232) Summary: CONTEXT: When the same RowVector is evaluated across many ExprSet instances (e.g. ~1800 times in some cases), the EvalCtx constructor's per-column isFlatEncoding/mayHaveNulls loop runs redundantly for each new instance of EvalCtx, even though the data is the same — 39% of CPU in production. WHAT: Add a new EvalCtx constructor overload that accepts a pre-computed inputFlatNoNulls flag, plus a static computeInputFlatNoNulls() helper. This lets callers compute the flag once and reuse it across all EvalCtx instances for the same RowVector. The original constructor now delegates to computeInputFlatNoNulls() to avoid code duplication. Differential Revision: D101418306
e45a320 to
5bd45b9
Compare
darxsys
pushed a commit
to darxsys/velox
that referenced
this pull request
Apr 17, 2026
…s flag (facebookincubator#17232) Summary: Pull Request resolved: facebookincubator#17232 CONTEXT: When the same RowVector is evaluated across many ExprSet instances (e.g. ~1800 times in some cases), the EvalCtx constructor's per-column isFlatEncoding/mayHaveNulls loop runs redundantly for each new instance of EvalCtx, even though the data is the same — 39% of CPU in production. WHAT: Add a new EvalCtx constructor overload that accepts a pre-computed inputFlatNoNulls flag, plus a static computeInputFlatNoNulls() helper. This lets callers compute the flag once and reuse it across all EvalCtx instances for the same RowVector. The original constructor now delegates to computeInputFlatNoNulls() to avoid code duplication. Differential Revision: D101418306
8db05d0 to
027e653
Compare
darxsys
pushed a commit
to darxsys/velox
that referenced
this pull request
Apr 20, 2026
…s flag (facebookincubator#17232) Summary: CONTEXT: When the same RowVector is evaluated across many ExprSet instances (e.g. ~1800 times in some cases), the EvalCtx constructor's per-column isFlatEncoding/mayHaveNulls loop runs redundantly for each new instance of EvalCtx, even though the data is the same — 39% of CPU in production. WHAT: Add a new EvalCtx constructor overload that accepts a pre-computed inputFlatNoNulls flag, plus a static computeInputFlatNoNulls() helper. This lets callers compute the flag once and reuse it across all EvalCtx instances for the same RowVector. The original constructor now delegates to computeInputFlatNoNulls() to avoid code duplication. Differential Revision: D101418306
…s flag (facebookincubator#17232) Summary: Pull Request resolved: facebookincubator#17232 CONTEXT: When the same RowVector is evaluated across many ExprSet instances (e.g. ~1800 times in some cases), the EvalCtx constructor's per-column isFlatEncoding/mayHaveNulls loop runs redundantly for each new instance of EvalCtx, even though the data is the same — 39% of CPU in production. WHAT: Add a new EvalCtx constructor overload that accepts a pre-computed inputFlatNoNulls flag, plus a static computeInputFlatNoNulls() helper. This lets callers compute the flag once and reuse it across all EvalCtx instances for the same RowVector. The original constructor now delegates to computeInputFlatNoNulls() to avoid code duplication. Differential Revision: D101418306
027e653 to
15df915
Compare
Yuhta
approved these changes
Apr 20, 2026
|
This pull request has been merged in 3eb73e9. |
shrshi
pushed a commit
to patdevinwilson/velox
that referenced
this pull request
Apr 23, 2026
…s flag (facebookincubator#17232) Summary: Pull Request resolved: facebookincubator#17232 CONTEXT: When the same RowVector is evaluated across many ExprSet instances (e.g. ~1800 times in some cases), the EvalCtx constructor's per-column isFlatEncoding/mayHaveNulls loop runs redundantly for each new instance of EvalCtx, even though the data is the same — 39% of CPU in production. WHAT: Add a new EvalCtx constructor overload that accepts a pre-computed inputFlatNoNulls flag, plus a static computeInputFlatNoNulls() helper. This lets callers compute the flag once and reuse it across all EvalCtx instances for the same RowVector. The original constructor now delegates to computeInputFlatNoNulls() to avoid code duplication. Reviewed By: Yuhta Differential Revision: D101418306 fbshipit-source-id: 68e78b5d47d1b9e36b5c3532dffaa3a5206f1a05
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
CONTEXT: When the same RowVector is evaluated across many ExprSet instances (e.g. ~1800 times in some cases), the EvalCtx constructor's per-column isFlatEncoding/mayHaveNulls loop runs redundantly for each new instance of EvalCtx, even though the data is the same — 39% of CPU in production.
WHAT: Add a new EvalCtx constructor overload that accepts a pre-computed inputFlatNoNulls flag, plus a static computeInputFlatNoNulls() helper. This lets callers compute the flag once and reuse it across all EvalCtx instances for the same RowVector. The original constructor now delegates to computeInputFlatNoNulls() to avoid code duplication.
Differential Revision: D101418306