Skip to content

Allow Numba NVRTC Binding Search Additional Paths#254

Merged
gmarkall merged 11 commits intoNVIDIA:mainfrom
isVoid:fea-additional-rtc-search-paths
May 20, 2025
Merged

Allow Numba NVRTC Binding Search Additional Paths#254
gmarkall merged 11 commits intoNVIDIA:mainfrom
isVoid:fea-additional-rtc-search-paths

Conversation

@isVoid
Copy link
Contributor

@isVoid isVoid commented May 16, 2025

Currently, the nvrtc binding searches a few hardcoded internal paths when looking for headers. This limits the foreign function usage to only depend on standard CUDA libraries. This PR adds CUDA_RTC_EXTRA_SEARCH_PATHS entry, a colon separated path list, which defines additional search paths when compiling external functions.

Note that these search paths are placed after the standard cudatookit and numba-cuda internal search paths.

closes #46

@copy-pr-bot
Copy link

copy-pr-bot bot commented May 16, 2025

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@isVoid
Copy link
Contributor Author

isVoid commented May 16, 2025

/ok to test

@isVoid isVoid marked this pull request as ready for review May 16, 2025 18:08
@copy-pr-bot
Copy link

copy-pr-bot bot commented May 16, 2025

Auto-sync is disabled for ready for review pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@isVoid
Copy link
Contributor Author

isVoid commented May 16, 2025

/ok to test

@isVoid
Copy link
Contributor Author

isVoid commented May 16, 2025

/ok to test

Copy link
Contributor

@gmarkall gmarkall left a comment

Choose a reason for hiding this comment

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

I think the feature and implementation looks good. I have a couple of items on the diff:

  • Can we use "NVRTC" rather than "RTC" in the config variable name to avoid ambiguity? I have tried to make this all as suggestions that can be accepted to avoid manually going and editing the code
  • I suggested some clarifications for readability in the docs - let me know if you prefer another form of any of these.
  • The override_config context manager is normally used to handle changing configuration during a test, so that the original configuration is restored if the test does not run to completion.

Following resolution of these I think this is good to merge.

@gmarkall gmarkall added the 4 - Waiting on author Waiting for author to respond to review label May 19, 2025
isVoid and others added 4 commits May 20, 2025 12:03
Co-authored-by: Graham Markall <535640+gmarkall@users.noreply.github.com>
Co-authored-by: Graham Markall <535640+gmarkall@users.noreply.github.com>
@isVoid
Copy link
Contributor Author

isVoid commented May 20, 2025

/ok to test

@gmarkall gmarkall added 5 - Ready to merge Testing and reviews complete, ready to merge and removed 4 - Waiting on author Waiting for author to respond to review labels May 20, 2025
@gmarkall gmarkall merged commit c8287f5 into NVIDIA:main May 20, 2025
37 checks passed
@isVoid isVoid mentioned this pull request May 21, 2025
isVoid added a commit that referenced this pull request May 21, 2025
- Allow External Code to Use Cooperative Group (#240)
- Improve debug info for kernel arguments (#242)
- Allow Numba NVRTC Binding Search Additional Paths (#254)
- Add Bfloat16 High Level API, Documentation (#245)
- add a test to use bf16 bindings inside device functions (#244)
- Change CI to only be manually triggered to save on CI runs (#252)
- Simplify the CI build and test matrix (#249)
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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEA] Support adding additional search paths for nvrtc.compile

2 participants

Comments