Hi,
I can't get default device queue using clGetCommandQueueInfo(.., CL_QUEUE_DEVICE_DEFAULT, ..) if before that command I increase and decrease reference counter of that default device queue. I get CL_INVALID_VALUE error. I don't get any errors from clRetainCommandQueue() and clReleaseCommandQueue().
clGetCommandQueueInfo(.., CL_QUEUE_DEVICE_DEFAULT, ..) works just fine if I don't change reference counter of the default device queue.
Test case in the attachment (just adjust intel platform index INTEL_PLATFORM_ID).