Skip to content

Add regex-flags member variable to internal libcudf reprog class - #22994

Merged
rapids-bot[bot] merged 2 commits into
NVIDIA:mainfrom
davidwendt:flags-to-remember
Jun 26, 2026
Merged

Add regex-flags member variable to internal libcudf reprog class#22994
rapids-bot[bot] merged 2 commits into
NVIDIA:mainfrom
davidwendt:flags-to-remember

Conversation

@davidwendt

@davidwendt davidwendt commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Description

Adds new member variable to hold the regex-flags specified by the regex-program interface so that it may be referenced more easily later for fast-path checking. This is some common changes needed in #22178 and #21936 and will help reduce the size of the changes for both and hopefully reduce confusion on the changes needed there.
Cleanup of related files is included as well.

Checklist

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

@davidwendt davidwendt self-assigned this Jun 25, 2026
@davidwendt
davidwendt requested a review from a team as a code owner June 25, 2026 19:07
@davidwendt davidwendt added 3 - Ready for Review Ready for review by team libcudf Affects libcudf (C++/CUDA) code. labels Jun 25, 2026
@davidwendt davidwendt added improvement Improvement / enhancement to an existing function non-breaking Non-breaking change labels Jun 25, 2026
@coderabbitai

coderabbitai Bot commented Jun 25, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The PR updates regex program declarations and implementation so reprog stores flags during construction and uses them in debug printing, and it adjusts count.cu’s anonymous-namespace scope and copyright header.

Changes

Regex program flags

Layer / File(s) Summary
Header declarations
cpp/include/cudf/strings/regex/regex_program.hpp, cpp/src/strings/regex/regcomp.h
The regex_program destructor moves into the public section, and reprog declares _flags, a regex_flags constructor, and print() const in the debug section.
Construction and print implementation
cpp/src/strings/regex/regcomp.cpp
reprog::create_from constructs with flags, the new reprog(regex_flags) definition initializes _flags, and debug reprog::print() reads _flags directly.

Search count namespace cleanup

Layer / File(s) Summary
Namespace boundary and header text
cpp/src/strings/search/count.cu
The copyright text changes, the anonymous namespace closes after counter_fn, and the later closing brace after detail::count is removed.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Suggested reviewers

  • vyasr
  • karthikeyann
  • bdice
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: adding a regex-flags member to the internal reprog class.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description check ✅ Passed The description matches the changeset: it adds regex-flags storage for regex-program and mentions related cleanup.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@vyasr

vyasr commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

/merge

@rapids-bot
rapids-bot Bot merged commit b2b2add into NVIDIA:main Jun 26, 2026
262 of 265 checks passed
@davidwendt
davidwendt deleted the flags-to-remember branch June 26, 2026 19:50
copy-pr-bot Bot pushed a commit that referenced this pull request Jun 29, 2026
)

Adds new member variable to hold the regex-flags specified by the regex-program interface so that it may be referenced more easily later for fast-path checking. This is some common changes needed in #22178 and #21936 and will help reduce the size of the changes for both and hopefully reduce confusion on the changes needed there.
Cleanup of related files is included as well.

Authors:
  - David Wendt (https://github.com/davidwendt)

Approvers:
  - Muhammad Haseeb (https://github.com/mhaseeb123)
  - Vyas Ramasubramani (https://github.com/vyasr)

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

Labels

3 - Ready for Review Ready for review by team improvement Improvement / enhancement to an existing function libcudf Affects libcudf (C++/CUDA) code. non-breaking Non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants