The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

sajis997 (1) [Avatar] Offline
#1
Hello forum,

On page 19, it is mentioned that if we set the num_entries variable to 0 , we shall get error with the function

clGetPlatformIDs(....)


But i am not getting any error. I am playing around with some of the opencl toys found here

http://davibu.interfree.it/.


And smallptgpu specifically setting the num_entries to 0


Any idea?


Regards
Sajjad
PetrSchreiber (2) [Avatar] Offline
#2
Re: more explanation - page 19
Hi,

you actually can pass num_entries parameter equal to zero, but only when platforms parameter is null. This is how it is used in smallptGPU.

You can read about it in the official specs:
http://www.khronos.org/registry/cl/sdk/1.0/docs/man/xhtml/clGetPlatformIDs.html


Petr