Skip to content

Conversation

@onursatici
Copy link
Contributor

Does this PR closes an open issue or discussion?

  • Closes #.

What changes are included in this PR?

make values child evaluation of an expression in the projection evaluation of a dict layout lazy. We want this because the current execute is assuming cpu only, with shared array we defer to the actual execute call to choose which execution it wants

What is the rationale for this change?

How is this change tested?

Are there any user-facing changes?

Signed-off-by: Onur Satici <[email protected]>
@onursatici onursatici added the changelog/performance A performance improvement label Feb 11, 2026
Comment on lines 123 to +126
self.values_array()
.map(move |array| {
let array = array?.apply(&expr)?;
// We execute the array to avoid re-evaluating for every split.
let mut ctx = ExecutionCtx::new(session);
Ok(array.execute::<Canonical>(&mut ctx)?.into_array())
Ok(SharedArray::new(array).into_array())
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this has double shared arrays ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, the first one to cache the values as is, and this caches the result of the expression, so it only is executed in the first split

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if the expr is root we would have shared(shared(values)) which is redundant but should be fine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/performance A performance improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants