Skip to content
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

[BUG] RMM_STATIC_CUDART needs to be set when statically linking cudart in JNI #10571

Closed
abellina opened this issue Apr 1, 2022 · 1 comment · Fixed by #10585
Closed

[BUG] RMM_STATIC_CUDART needs to be set when statically linking cudart in JNI #10571

abellina opened this issue Apr 1, 2022 · 1 comment · Fixed by #10585
Assignees
Labels
bug Something isn't working Java Affects Java cuDF API. Spark Functionality that helps Spark RAPIDS

Comments

@abellina
Copy link
Contributor

abellina commented Apr 1, 2022

RMM turns off the async allocator depending on what is available in the linked cudart. We have been linking cudart statically, but we haven't set this preprocessor directive (RMM_STATIC_CUDART) that actually lets RMM know that we did, so it tries to dynamically load cudart symbols, which could lead to picking up a libcudart.so that isn't the one we statically linked with (an older one, without ASYNC support).

We found this bug when trying the ASYNC allocator again in 22.06. We need to fix in the cudfjni targets.

@abellina abellina added bug Something isn't working Needs Triage Need team to review and classify libcudf Affects libcudf (C++/CUDA) code. Java Affects Java cuDF API. labels Apr 1, 2022
@sameerz sameerz added the Spark Functionality that helps Spark RAPIDS label Apr 1, 2022
@abellina abellina removed the libcudf Affects libcudf (C++/CUDA) code. label Apr 1, 2022
@abellina
Copy link
Contributor Author

abellina commented Apr 1, 2022

It looks like this only affects libcudfjni, not libcudf @sameerz fyi.

@abellina abellina changed the title [BUG] RMM_STATIC_CUDART needs to be set when statically linking cudart [BUG] RMM_STATIC_CUDART needs to be set when statically linking cudart in JNI Apr 4, 2022
rapids-bot bot pushed a commit that referenced this issue Apr 4, 2022
…UDA runtime (#10585)

Fixes #10571.

This fixes the JNI CMakeLists.txt so that RMM will automatically get the `RMM_STATIC_CUDART` define added to the build when `CUDA_STATIC_RUNTIME=ON`.  Verified by building with Javva CI Dockerfile with static CUDA runtime and examining the build command-lines and flag definitions in java/target/cmake-build/CMakeFiles.

Authors:
  - Jason Lowe (https://github.com/jlowe)

Approvers:
  - Alessandro Bellina (https://github.com/abellina)

URL: #10585
@bdice bdice removed the Needs Triage Need team to review and classify label Mar 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Java Affects Java cuDF API. Spark Functionality that helps Spark RAPIDS
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants