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

Allow obtaining a pointer's device and context without wrapping it #463

Closed
eyalroz opened this issue Feb 6, 2023 · 0 comments
Closed

Allow obtaining a pointer's device and context without wrapping it #463

eyalroz opened this issue Feb 6, 2023 · 0 comments

Comments

@eyalroz
Copy link
Owner

eyalroz commented Feb 6, 2023

The wrapped pointer_t class is nice, but - we shouldn't have to create a wrapped object only to run the method which obtains the device or the context for a pointer. There should be freestanding functions which do that.

@eyalroz eyalroz added the task label Feb 6, 2023
@eyalroz eyalroz self-assigned this Feb 6, 2023
eyalroz added a commit that referenced this issue Feb 6, 2023
* Can now get the device for a pointer in CUDA before 9.2 - by getting the context, then getting the device for the context
* Added `memory::device_of()` and `memory::context_of()`
* Added `memory::detail_` functions for returning the context handle or device id of a pointer, without having to remember the pointer attributes mechanism
eyalroz added a commit that referenced this issue Feb 10, 2023
* Can now get the device for a pointer in CUDA before 9.2 - by getting the context, then getting the device for the context
* Added `memory::device_of()` and `memory::context_of()`
* Added `memory::detail_` functions for returning the context handle or device id of a pointer, without having to remember the pointer attributes mechanism
eyalroz added a commit that referenced this issue Mar 9, 2023
* Can now get the device for a pointer in CUDA before 9.2 - by getting the context, then getting the device for the context
* Added `memory::device_of()` and `memory::context_of()`
* Added `memory::detail_` functions for returning the context handle or device id of a pointer, without having to remember the pointer attributes mechanism
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant