|
HIP: Heterogenous-computing Interface for Portability
|
Functions | |
| hipError_t | hipDeviceCanAccessPeer (int *canAccessPeer, int device, int peerDevice) |
| Determine if a device can access a peer's memory. More... | |
| hipError_t | hipDeviceDisablePeerAccess (int peerDevice) |
| Disables registering memory on peerDevice for direct access from the current device. More... | |
| hipError_t | hipDeviceEnablePeerAccess (int peerDevice, unsigned int flags) |
| Enables registering memory on peerDevice for direct access from the current device. More... | |
| hipError_t | hipMemcpyPeer (void *dst, int dstDevice, const void *src, int srcDevice, size_t sizeBytes) |
| Copies memory from one device to memory on another device. More... | |
| hipError_t | hipMemcpyPeerAsync (void *dst, int dstDevice, const void *src, int srcDevice, size_t sizeBytes, hipStream_t stream=0) |
| Copies memory from one device to memory on another device. More... | |
| hipError_t hipDeviceCanAccessPeer | ( | int * | canAccessPeer, |
| int | device, | ||
| int | peerDevice | ||
| ) |
Determine if a device can access a peer's memory.
| [out] | canAccessPeer | returns true if specified devices are peers. |
| [in] | device | |
| [in] | peerDevice | Returns "1" in canAccessPeer if the specified device is capable of directly accessing memory physically located on peerDevice , or "0" if not. |
| hipError_t hipDeviceDisablePeerAccess | ( | int | peerDevice | ) |
Disables registering memory on peerDevice for direct access from the current device.
If there are any allocations on peerDevice which were registered in the current device using hipPeerRegister() then these allocations will be automatically unregistered. Returns hipErrorPeerAccessNotEnabled if direct access to memory on peerDevice has not yet been enabled from the current device.
| [in] | peerDevice | TODO:cudaErrorPeerAccessNotEnabled and cudaErrorInvalidDevice error not supported in HIP, return hipErrorUnknown Returns hipSuccess, hipErrorUnknown |
| hipError_t hipDeviceEnablePeerAccess | ( | int | peerDevice, |
| unsigned int | flags | ||
| ) |
Enables registering memory on peerDevice for direct access from the current device.
| [in] | peerDevice | |
| [in] | flags | TODO:cudaErrorInvalidDevice error not supported in HIP, return hipErrorUnknown Returns hipSuccess, hipErrorInvalidDevice, hipErrorInvalidValue, hipErrorUnknown |
| hipError_t hipMemcpyPeer | ( | void * | dst, |
| int | dstDevice, | ||
| const void * | src, | ||
| int | srcDevice, | ||
| size_t | sizeBytes | ||
| ) |
Copies memory from one device to memory on another device.
| [out] | dst | - Destination device pointer. |
| [in] | dstDevice | - Destination device |
| [in] | src | - Source device pointer |
| [in] | srcDevice | - Source device |
| [in] | sizeBytes | - Size of memory copy in bytes |
Returns hipSuccess, hipErrorInvalidValue, hipErrorInvalidDevice
| hipError_t hipMemcpyPeerAsync | ( | void * | dst, |
| int | dstDevice, | ||
| const void * | src, | ||
| int | srcDevice, | ||
| size_t | sizeBytes, | ||
| hipStream_t | stream | ||
| ) |
Copies memory from one device to memory on another device.
| [out] | dst | - Destination device pointer. |
| [in] | dstDevice | - Destination device |
| [in] | src | - Source device pointer |
| [in] | srcDevice | - Source device |
| [in] | sizeBytes | - Size of memory copy in bytes |
| [in] | stream | - Stream identifier |
Returns hipSuccess, hipErrorInvalidValue, hipErrorInvalidDevice
1.8.6