MCPcopy Create free account
hub / github.com/RenderKit/oidn / newDevice

Function newDevice

devices/hip/hip_module.cpp:17–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15 }
16
17 Ref<Device> newDevice(const int* deviceIDs, const hipStream_t* streams, int numPairs) override
18 {
19 if (numPairs != 1)
20 throw Exception(Error::InvalidArgument, "invalid number of HIP devices/streams");
21 if (deviceIDs == nullptr)
22 throw Exception(Error::InvalidArgument, "array of HIP devices is null");
23 if (streams == nullptr)
24 throw Exception(Error::InvalidArgument, "array of HIP streams is null");
25
26 return makeRef<HIPDevice>(deviceIDs[0], streams[0]);
27 }
28
29 Ref<Device> newDevice(const Ref<PhysicalDevice>& physicalDevice) override
30 {

Callers 4

newDeviceMethod · 0.50
mainFunction · 0.50
makeDeviceFunction · 0.50
mainFunction · 0.50

Calls 1

ExceptionFunction · 0.85

Tested by 1

makeDeviceFunction · 0.40