1 Description: Allow clCreateCommandQueue to create out-of-order queues
3 Author: Rebecca N. Palmer <rebecca_palmer@zoho.com>
4 Forwarded: https://lists.freedesktop.org/archives/beignet/2018-July/009215.html
6 --- a/src/cl_api_command_queue.c
7 +++ b/src/cl_api_command_queue.c
8 @@ -27,35 +27,11 @@ clCreateCommandQueue(cl_context context,
9 cl_command_queue_properties properties,
12 - cl_command_queue queue = NULL;
13 - cl_int err = CL_SUCCESS;
16 - if (!CL_OBJECT_IS_CONTEXT(context)) {
17 - err = CL_INVALID_CONTEXT;
21 - err = cl_devices_list_include_check(context->device_num, context->devices, 1, &device);
25 - if (properties & ~(CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE | CL_QUEUE_PROFILING_ENABLE)) {
26 - err = CL_INVALID_VALUE;
30 - if (properties & CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE) { /*not supported now.*/
31 - err = CL_INVALID_QUEUE_PROPERTIES;
35 - queue = cl_create_command_queue(context, device, properties, 0, &err);
41 + cl_queue_properties props[3];
42 + props[0] = CL_QUEUE_PROPERTIES;
43 + props[1] = properties;
45 + return clCreateCommandQueueWithProperties(context, device, props, errcode_ret);
48 /* 2.0 new API for create command queue. */