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

Fix resize! when pool=none is in use #2613

Merged
merged 3 commits into from
Jan 10, 2025
Merged

Conversation

luraess
Copy link
Contributor

@luraess luraess commented Jan 9, 2025

This PR addresses the issue where calling resize! errors if the CUDA memory pool is disabled. The use case is e.g. when using CUDA-aware MPI, which currently requires to disable the memory pool.

This PR replaces the alloc function used in resize! by pool_alloc, which now correctly captures the usage of a memory pool and would default to non-asynchronous memory initialisation if the usage of a memory pool is disabled.

In addition, this PR also defaults the async keyword argument in alloc to false instead of making it true if the target device supports a memory pool.

Copy link
Member

@maleadt maleadt left a comment

Choose a reason for hiding this comment

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

LGTM.

@maleadt maleadt merged commit 774abc6 into JuliaGPU:master Jan 10, 2025
1 of 3 checks passed
@luraess
Copy link
Contributor Author

luraess commented Jan 10, 2025

Would it be possible to get this fix included in a patch release soon?

@maleadt
Copy link
Member

maleadt commented Jan 10, 2025

Yes, but I want to finalize the cached allocator implementation first.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants