-
Notifications
You must be signed in to change notification settings - Fork 1k
Cleanup duplicated code in hybrid scan #21353
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
rapids-bot
merged 4 commits into
rapidsai:main
from
mhaseeb123:improve/deduplicate-hybrid-scan
Feb 6, 2026
Merged
Changes from 1 commit
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -288,13 +288,12 @@ class hybrid_scan_reader_impl : public parquet::detail::reader_impl { | |
| /** | ||
| * @brief Initialize the necessary options related internal variables for use later on | ||
| * | ||
| * @param row_group_indices Row group indices to read | ||
| * @param options Reader options | ||
| * @param stream CUDA stream used for device memory operations and kernel launches | ||
| * @param mr Device memory resource used to allocate the returned column's device memory | ||
| */ | ||
| void initialize_options(cudf::host_span<std::vector<size_type> const> row_group_indices, | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We only ever need |
||
| parquet_reader_options const& options, | ||
| void initialize_options(parquet_reader_options const& options, | ||
| std::size_t num_sources, | ||
| rmm::cuda_stream_view stream, | ||
| rmm::device_async_resource_ref mr); | ||
|
|
||
|
|
@@ -333,6 +332,30 @@ class hybrid_scan_reader_impl : public parquet::detail::reader_impl { | |
| get_input_column_chunk_byte_ranges( | ||
| cudf::host_span<std::vector<size_type> const> row_group_indices) const; | ||
|
|
||
| /** | ||
| * @brief Helper to prepare converted filter expression and output column data types | ||
| * | ||
| * @param options Parquet reader options | ||
| * @return A pair of a converted filter expression and a vector of ouptut column data types | ||
| */ | ||
| std::pair<named_to_reference_converter, std::vector<cudf::data_type>> | ||
| prepare_filter_and_output_types(parquet_reader_options const& options); | ||
|
|
||
| /** | ||
| * @brief Helper to prepare column materialization | ||
| * | ||
| * @param read_columns_mode Read mode indicating if we are reading filter or payload columns | ||
| * @param num_sources Number of input sources | ||
| * @param options Parquet reader options | ||
| * @param stream CUDA stream used for device memory operations and kernel launches | ||
| * @param mr Device memory resource used to allocate the device memory for the output columns | ||
| */ | ||
| void prepare_materialization(read_columns_mode read_columns_mode, | ||
| std::size_t num_sources, | ||
| parquet_reader_options const& options, | ||
| rmm::cuda_stream_view stream, | ||
| rmm::device_async_resource_ref mr); | ||
|
|
||
| /** | ||
| * @brief Perform the necessary data preprocessing for parsing file later on | ||
| * | ||
|
|
||
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Open to suggestions for names of these two helpers.