[GLUTEN-8453][VL] Follow-up to #8454 to add a ensureVeloxBatch API for limited use cases#8463
Merged
zhztheplayer merged 4 commits intoapache:mainfrom Jan 9, 2025
Merged
Conversation
ensureVeloxBatch API for limited use casesensureVeloxBatch API for limited use cases
Member
Author
|
cc @ArnavBalyan @jinchengchenghh Thanks |
rui-mo
approved these changes
Jan 9, 2025
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.
This is a follow-up change for #8454.
Usually a Gluten query plan knows exactly the batch type of data it processes with the help from Gluten's transition planner. Table cache write is an exception here because vanilla Spark's cache generation code simply calls API
CachedBatchSerializer#convertColumnarBatchToCachedBatchfor a child plan withsupportsColumnar=true. Hence, we have to dynamically do to-Velox batch conversions in the implementation code ofCachedBatchSerializer#convertColumnarBatchToCachedBatchbecause we don't know the batch type the child plan outputs.The patch adds an
ensureVeloxBatchAPI for dynamical to-Velox batch conversion. The API should only be used in table cache write or similar scenarios that explicit transitions are not able to add.The patch adds a test case for the original issue #8453 also.