String, name of the kernel.
Array[(String, NDArray)], array of input names and ndarray.
Array[(String, NDArray)], array of output names and ndarray.
String, the actual kernel code. Note that this is only the body of the kernel, i.e. after { and before }. Rtc will decorate the kernel. For example, if name = "mykernel" and inputs = Array(("x", NDArray.zeros(10))) outputs = Array(("y", NDArray.zeros(10))) kernel = "y[threadIdx.x] = x[threadIdx.x];", the kernel that is compile will be: extern "C" global mykernel(float *x, float *y) { const int x_ndim = 1; const int x_dims[] = { 10 }; const int y_ndim = 1; const int y_dims[] = { 10 };
y[threadIdx.x] = x[threadIdx.x]; }
Free the rtc handle.
Free the rtc handle. The object shall never be used after it is disposed.
run the kernel.
This class allow you to write cuda kernel in Scala and call them with NDArray.