mirror of https://github.com/BOINC/boinc.git
15 lines
430 B
Common Lisp
15 lines
430 B
Common Lisp
|
/*!
|
||
|
* Sample kernel which multiplies every element of the input array with
|
||
|
* a constant and stores it at the corresponding output array
|
||
|
*/
|
||
|
|
||
|
|
||
|
__kernel void templateKernel(__global unsigned int * output,
|
||
|
__global unsigned int * input,
|
||
|
const unsigned int multiplier)
|
||
|
{
|
||
|
uint tid = get_global_id(0);
|
||
|
|
||
|
output[tid] = input[tid] * multiplier;
|
||
|
}
|