pub unsafe extern "C" fn cudaMemset(
devPtr: *mut c_void,
value: c_int,
count: size_t,
) -> cudaError_tExpand description
Initializes or sets device memory to a value.
Fills the first count bytes of the memory area pointed to by devPtr with the constant byte value value.
Note that this function is asynchronous with respect to the host unless devPtr refers to pinned host memory.
Note that this function may also return error codes from previous, asynchronous launches.
Note: See also memset synchronization details.
Note that this function may also return cudaError_t::CUDA_ERROR_NOT_INITIALIZED, cudaErrorInsufficientDriver or cudaError_t::CUDA_ERROR_NO_DEVICE if this call tries to initialize internal CUDA RT state.
Note that as specified by cudaStreamAddCallback no CUDA function may be called from callback. cudaError_t::CUDA_ERROR_NOT_PERMITTED may, but is not guaranteed to, be returned as a diagnostic in such case.
§Parameters
devPtr: Pointer to device memory.value: Value to set for each byte of specified memory.count: Size in bytes to set.
§Return value
See also: cuMemsetD8, cuMemsetD16, cuMemsetD32.