-
Notifications
You must be signed in to change notification settings - Fork 238
Sycl umpire #1416
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
base: master
Are you sure you want to change the base?
Sycl umpire #1416
Conversation
| #if defined(HYPRE_USING_SYCL) | ||
| HYPRE_Int device_id; | ||
| hypre_GetDevice(&device_id); | ||
| hypre_sprintf(resource_name, "%s::%d", "DEVICE", device_id); | ||
| #else | ||
| const hypre_int device_id = hypre_HandleDevice(handle); | ||
| hypre_sprintf(resource_name, "%s::%d", "DEVICE", device_id); | ||
| #endif |
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.
Minor reorg:
| #if defined(HYPRE_USING_SYCL) | |
| HYPRE_Int device_id; | |
| hypre_GetDevice(&device_id); | |
| hypre_sprintf(resource_name, "%s::%d", "DEVICE", device_id); | |
| #else | |
| const hypre_int device_id = hypre_HandleDevice(handle); | |
| hypre_sprintf(resource_name, "%s::%d", "DEVICE", device_id); | |
| #endif | |
| #if defined(HYPRE_USING_SYCL) | |
| HYPRE_Int device_id; | |
| hypre_GetDevice(&device_id); | |
| #else | |
| const hypre_int device_id = hypre_HandleDevice(handle); | |
| #endif | |
| hypre_sprintf(resource_name, "%s::%d", "DEVICE", device_id); |
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.
Also, just curious... Shouldn't hypre_HandleDevice(handle); work for SYCL as well? Curious why we need to do something different for SYCL...
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.
The type of hypre_HandleDevice(handle) is different for sycl. It's an actual sycl device object rather than just an integer ID.
… not seem to have the intended effect.
…l no luck. Commenting this out for now.
Add umpire support for the sycl backend.