-
Notifications
You must be signed in to change notification settings - Fork 915
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
[JNI] Expose java API for cudf::io::config_host_memory_resource #15745
[JNI] Expose java API for cudf::io::config_host_memory_resource #15745
Conversation
* Sets the size of the cuDF default pinned pool. | ||
* | ||
* @note This has to be called before cuDF functions are executed. | ||
* @param size |
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.
* @param size | |
* @param size ??? |
* Sets the size of the cuDF default pinned pool. | ||
* | ||
* @note This has to be called before cuDF functions are executed. | ||
* @param size |
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.
* @param size | |
* @param size ??? |
java/src/main/native/src/RmmJni.cpp
Outdated
cudf::io::config_host_memory_resource(size); | ||
try { | ||
cudf::jni::auto_set_device(env); | ||
cudf::io::config_host_memory_resource(size); |
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.
Duplicate calls?
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.
nice catch, this was a copy and paste error
@@ -1106,4 +1106,15 @@ JNIEXPORT void JNICALL Java_ai_rapids_cudf_Rmm_freeFromFallbackPinnedPool(JNIEnv | |||
} | |||
CATCH_STD(env, ) | |||
} | |||
|
|||
JNIEXPORT void JNICALL Java_ai_rapids_cudf_Rmm_configureDefaultCudfPinnedPoolSize(JNIEnv* env, | |||
jclass clazz, |
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.
Remove name of the unused var to avoid compile warning.
jclass clazz, | |
jclass, |
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.
We have this in every single API in this file and probably other, but I am not seeing warnings on it. I'd rather keep it as is at this stage.
/ok to test |
/okay to test |
/merge |
…ce (rapidsai#15745)" This reverts commit 8b72455.
…y_resource (rapidsai#15745)"" This reverts commit ff392b5.
This PR depends on #15665 and so it won't build until that PR merges.
Adds support for
cudf::io::config_host_memory_resource
which is being worked on in #15665. In 24.06 we are going to disable the cuDF pinned pool and look into this more in 24.08.We currently have a pinned pooled resource that has been setup to share pinned memory with other APIs we use from java, so we wanted to prevent extra pinned memory being created by default, and @vuule has added an API for us to call to accomplish this.