HIP icon indicating copy to clipboard operation
HIP copied to clipboard

Allow querying LUID from device for better interoperability

Open Nielsbishere opened this issue 2 years ago • 6 comments

Intel's open image denoiser (oidn) has a layer to better interface between HIP, CUDA and SYCL. This layer has a feature to query a device's LUID which is in turn used to create a device for interoperability between for example DirectX12 (since that only has the ability to get the adapter's LUID). Unfortunately due to HIP's limitation for querying a LUID (according to intel: https://github.com/OpenImageDenoise/oidn/issues/163) this doesn't seem possible right now. This would make implementing OIDN "hardware support" (gpu acceleration) in our engine to be quite bothersome (if it's even possible). Is it possible to get this feature natively in HIP?

Nielsbishere avatar Jun 08 '23 17:06 Nielsbishere

I have check the hipDeviceProp_t, it seems that only pci bus can be used to locate a physical video card. Here is a function to get luid from it:

https://github.com/scarsty/mlcc/blob/master/vramusage.h

scarsty avatar Oct 05 '23 15:10 scarsty

@scarsty Thank you for your help, I'll forward this to oidn as well so it could be used if they desire.

Nielsbishere avatar Oct 05 '23 16:10 Nielsbishere

@Nielsbishere : Did you try hipDeviceGetUuid?

mangupta avatar Oct 06 '23 03:10 mangupta

@Nielsbishere : Did you try hipDeviceGetUuid?

I have tried it. The result is "XX", and I thought it is of no use.

scarsty avatar Oct 06 '23 04:10 scarsty

@Nielsbishere Has your issue been resolved? If so, please close ticket. Thanks!

ppanchad-amd avatar Apr 25 '24 17:04 ppanchad-amd

Adding @atafra here to see if there's any change here.

Nielsbishere avatar Apr 28 '24 10:04 Nielsbishere

ROCm 6+ supports LUID query. Windows HIP SDK 6.1 just got released. OIDN now needs to enable LUID support on HIP devices: https://github.com/RenderKit/oidn/issues/230.

salipourto avatar Jul 10 '24 18:07 salipourto