Skip to content

Cleanup duplicated code in hybrid scan#21353

Merged
rapids-bot[bot] merged 4 commits intorapidsai:mainfrom
mhaseeb123:improve/deduplicate-hybrid-scan
Feb 6, 2026
Merged

Cleanup duplicated code in hybrid scan#21353
rapids-bot[bot] merged 4 commits intorapidsai:mainfrom
mhaseeb123:improve/deduplicate-hybrid-scan

Conversation

@mhaseeb123
Copy link
Member

Description

This PR cleans up the hybrid scan reader implementation by moving duplicated code into helper functions. No code logic has been changed.

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@mhaseeb123 mhaseeb123 requested a review from a team as a code owner February 5, 2026 22:05
@github-actions github-actions bot added the libcudf Affects libcudf (C++/CUDA) code. label Feb 5, 2026
return {std::move(expr_conv), std::move(output_dtypes)};
}

void hybrid_scan_reader_impl::prepare_materialization(read_columns_mode read_columns_mode,
Copy link
Member Author

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.

* @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,
Copy link
Member Author

Choose a reason for hiding this comment

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

We only ever need row_group_indices.size() in here so just directly take in num_sources

@mhaseeb123 mhaseeb123 added 3 - Ready for Review Ready for review by team non-breaking Non-breaking change cuIO cuIO issue Reliability labels Feb 5, 2026
@mhaseeb123 mhaseeb123 changed the title Clean up duplicated code in hybrid scan Cleanup duplicated code in hybrid scan Feb 5, 2026
@mhaseeb123 mhaseeb123 added the improvement Improvement / enhancement to an existing function label Feb 5, 2026
@mhaseeb123 mhaseeb123 added 4 - Needs Review Waiting for reviewer to review or respond 5 - Ready to Merge Testing and reviews complete, ready to merge and removed 3 - Ready for Review Ready for review by team 4 - Needs Review Waiting for reviewer to review or respond labels Feb 5, 2026
@mhaseeb123
Copy link
Member Author

/merge

@rapids-bot rapids-bot bot merged commit 5f37ae4 into rapidsai:main Feb 6, 2026
117 checks passed
@mhaseeb123 mhaseeb123 deleted the improve/deduplicate-hybrid-scan branch February 6, 2026 23:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

5 - Ready to Merge Testing and reviews complete, ready to merge cuIO cuIO issue improvement Improvement / enhancement to an existing function libcudf Affects libcudf (C++/CUDA) code. non-breaking Non-breaking change Reliability

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants