Skip to main content

cudaMemcpyArrayToArray

Function cudaMemcpyArrayToArray 

Source
pub unsafe extern "C" fn cudaMemcpyArrayToArray(
    dst: cudaArray_t,
    wOffsetDst: size_t,
    hOffsetDst: size_t,
    src: cudaArray_const_t,
    wOffsetSrc: size_t,
    hOffsetSrc: size_t,
    count: size_t,
    kind: cudaMemcpyKind,
) -> cudaError_t
๐Ÿ‘ŽDeprecated
Expand description

Copies data between host and device.

Copies count bytes from the CUDA array src starting at hOffsetSrc rows and wOffsetSrc bytes from the upper left corner to the CUDA array dst starting at hOffsetDst rows and wOffsetDst bytes from the upper left corner, where kind specifies the direction of the copy, and must be one of cudaMemcpyKind::cudaMemcpyHostToHost, cudaMemcpyKind::cudaMemcpyHostToDevice, cudaMemcpyKind::cudaMemcpyDeviceToHost, cudaMemcpyKind::cudaMemcpyDeviceToDevice, or cudaMemcpyKind::cudaMemcpyDefault. Passing cudaMemcpyKind::cudaMemcpyDefault is recommended, in which case the type of transfer is inferred from the pointer values. However, cudaMemcpyKind::cudaMemcpyDefault is only allowed on systems that support unified virtual addressing.

ยงParameters

  • dst: Destination memory address.
  • wOffsetDst: Destination starting X offset (columns in bytes).
  • hOffsetDst: Destination starting Y offset (rows).
  • src: Source memory address.
  • wOffsetSrc: Source starting X offset (columns in bytes).
  • hOffsetSrc: Source starting Y offset (rows).
  • count: Size in bytes to copy.
  • kind: Type of transfer.