Copies memory from one device to memory on another device. dst
is the base device pointer of the destination memory and dstDevice
is the destination device. src
is the base device pointer of the source memory and srcDevice
is the source device. count
specifies the number of bytes to copy.
Note that this function is asynchronous with respect to the host and all work in other streams and other devices.
- Parameters:
-
| dst | - Destination device pointer |
| dstDevice | - Destination device |
| src | - Source device pointer |
| srcDevice | - Source device |
| count | - Size of memory copy in bytes |
| stream | - Stream identifier |
- Returns:
- cudaSuccess, cudaErrorInvalidValue, cudaErrorInvalidDevice
- Note:
- Note that this function may also return error codes from previous, asynchronous launches.
- See also:
- cudaMemcpy, cudaMemcpyPeer, cudaMemcpyPeer3D, cudaMemcpyAsync, cudaMemcpy3DPeerAsync