Something I'm writing requires me to query information about an event. Specifically, I'm running into a issue when using clGetEventInfo to get an event command type (CL_COMMAND_TASK, CL_COMMAND_NDRANGE_KERNEL, CL_COMMAND_NATIVE_KERNEL, etc.).
For this I get CL_COMMAND_NDRANGE_KERNEL whether I'm using clEnqueueNDRangeKernel or clEnqueueTask. When I use Intel's platform rather than AMD's, I get the correct event command type for it (CL_COMMAND_TASK for clEnqueueTask and CL_COMMAND_NDRANGE_KERNEL for clEnqeueNDRangeKernel).
I wrote a little test program to see if it being caused by something else in my code, and it's still happening. In the test I even check a non-AMD platform (in my case, Intel).
I attempted to look it up and see if this was an intentional thing AMD does or it was a bug of some sort but couldn't find anything. Has anyone run into this? Better yet, does running the attached code give the same result?
Thanks for reporting this. I checked and found the same output as yours. I need to confirm from the driver/run-time team.
Note: In OpenCL 2.0, both clEnqueueTask and CL_COMMAND_TASK are deprecated.
Thank you for checking! And thank you for the note, I was using OpenCL 1.2, but I didn't even think of it being a version difference.