How to get Ns

I know that we can pass in Ns as an option argument to a global frunction. Is there some built in variable that contains this value along the lines of threadIdx, blockIdx, etc.? I can’t seem to find it if there is. Thanks.

I mean to post this in programming and development. Sorry, guys.

What is Ns ???

The name of the parameter in the kernel call which sets how much dynamic shared memory to allocate per block. See 4.2.3 of the guide.

okay, then I can say I never heard of it being available as a built in variable. passing it to the kernel and letting tid==0 put it in a shared variable will do the same however. blockDim, blockIdx and gridDim are also in shared memory.
threadIdx.x is standard in register 0.

All right. It’s fairly clear now that there is no such built in variable. I will continue passing it in as an argument.