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

Java: Add leak tracking for Scalar instances #15121

Merged
merged 2 commits into from
Feb 23, 2024

Conversation

jlowe
Copy link
Member

@jlowe jlowe commented Feb 22, 2024

Description

Adds Scalar as another Closeable instance that can be tracked via the leak tracking framework in the cudf Java bindings.

Checklist

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

@jlowe jlowe added Java Affects Java cuDF API. Spark Functionality that helps Spark RAPIDS improvement Improvement / enhancement to an existing function non-breaking Non-breaking change labels Feb 22, 2024
@jlowe jlowe self-assigned this Feb 22, 2024
@jlowe jlowe requested a review from a team as a code owner February 22, 2024 22:29
Copy link
Contributor

@ttnghia ttnghia left a comment

Choose a reason for hiding this comment

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

Why didn't we do that before?

@jlowe
Copy link
Member Author

jlowe commented Feb 22, 2024

Why didn't we do that before?

Good question. I suspect it was skipped back when we weren't sure how much overhead this was going to add (we are creating more objects to do this tracking, adding to GC overhead), and scalars back then were guaranteed to be tiny (no list/struct scalar support in the old days) so not as worried about leaking. However scalars, even though they're tiny, are really good at fragmenting GPU memory when they're leaked.

@jlowe
Copy link
Member Author

jlowe commented Feb 23, 2024

/merge

@rapids-bot rapids-bot bot merged commit 8e87335 into rapidsai:branch-24.04 Feb 23, 2024
68 checks passed
@jlowe jlowe deleted the jni-scalar-leak-track branch February 23, 2024 19:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Improvement / enhancement to an existing function Java Affects Java cuDF API. non-breaking Non-breaking change Spark Functionality that helps Spark RAPIDS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants