richeek.arya

OpenCL kernel arguments without address space qualifiers

Discussion created by richeek.arya on Feb 23, 2011
Latest reply on Feb 24, 2011 by richeek.arya

Hi all,

I was working in OpenCL development and had some conceptual questions.

In the the OpenCL manual it is written that:

"All arguments to a __kernel function shall be in the __private
address space."

Suppose I take a protoype kernel definition from the sample codes:

void matrixTranspose(__global float * output,
                     __global float * input,
                     __local  float * block,
                     const    uint    width,
                     const    uint    height,
                     const    uint blockSize
                       )

Now I have two questions in that:

1. All the aruments preciding with __global and __local are defined in global address space since they explicitly have "global" address qualifier. Is it true?

2. For rest of the arguments(width, height and blockSize) are they in the __private address space?  Does it mean every thread has copy of those variables?

Thanks

Richeek

Outcomes