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

[C++] Invoke storage allocation for CUDA Graph explicitly #3042

Merged

Conversation

MasterJH5574
Copy link
Member

This PR adds a function that invokes the storage allocation function generated by CUDA Graph rewrite. With this function, we now manually trigger the storage allocation at initialization time.

The reason we need this is because that the storage allocation may contain CUDA IPC memory alloc that has to run through a Disco session. So when a function that needs CUDA graph storage allocation runs first outside a Disco session, there might be error caused if we did not initialize the allocation in advance.

This PR adds a function that invokes the storage allocation function
generated by CUDA Graph rewrite. With this function, we now manually
trigger the storage allocation at initialization time.

The reason we need this is because that the storage allocation may
contain CUDA IPC memory alloc that has to run through a Disco session.
So when a function that needs CUDA graph storage allocation runs first
outside a Disco session, there might be error caused if we did not
initialize the allocation in advance.
@MasterJH5574 MasterJH5574 merged commit d23d6f5 into mlc-ai:main Nov 21, 2024
2 checks passed
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.

1 participant