I think when you create command queue you should add CL_QUEUE_PROFILING_ENABLE flag to get timing info out of kernel. I did it like this:
commandQueue = clCreateCommandQueue(context, devices, CL_QUEUE_PROFILING_ENABLE, &status);
Hope it works for you too!
Thanks for your help. This was not what I was looking for. I am not looking to time the amout of time the kernel tool to execute. I am trying to figure out the amount of time it took to build (compiling) the kernel.
I guess you should use some timer across the clCreateProgram + clBuildProgram for that. But this is purely implementation behind and I am not aware of AMD's implementation details, so it is just a guess.
The above code is doing exactly that. For some strange reason it hangs inside clCreateCommandQueue
I am able to run your code. MY system is Vista64 HD 5770 .
Value of Clocks_per_sec : 0.000000 ticks/sec
freq test: 25000000 ticks/sec
QueryPerformanceCounter testpoint : 300455847858 ticks
Elapsed CPU time test: 0.130063040 sec ticks 3251576
Press any key to continue . . .