MATLAB PARALLEL COMPUTING TOOLBOX - S Guia do Utilizador Página 567

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
Vista de página 566
parallel.gpu.CUDAKernel
11-223
int idx = blockIdx.x * blockDim.x + threadIdx.x;
if (idx < vecLen) {
pi[idx] += c;
}
and simpleEx.ptx contains the PTX resulting from compiling simpleEx.cu into
PTX, both of the following statements return a kernel object that you can use to call the
addToVector CUDA kernel.
kern = parallel.gpu.CUDAKernel('simpleEx.ptx', ...
'simpleEx.cu');
kern = parallel.gpu.CUDAKernel('simpleEx.ptx', ...
'float *, float, int');
See Also
arrayfun | feval | existsOnGPU | gpuArray | reset
Vista de página 566
1 2 ... 562 563 564 565 566 567 568 569 570 571 572 ... 655 656

Comentários a estes Manuais

Sem comentários