test CL_QUEUE_ARRAY_PROPERTIES query (#925)

* OpenCL 3.0 test CL_QUEUE_PROPERTIES_ARRAY

* add verification if requested_size <= CL_DEVICE_QUEUE_ON_DEVICE_MAX_SIZE
* remove test_case - set NULL properties, get not empty array with 0 terminator
* add printing test_case description

* change logic of checking if requested properties are supported by device
depending on host/device type queue.

* fix a few bugs, rename test for consistency

* add utility function for comparing properties

Co-authored-by: Grzegorz Wawiorko <grzegorz.wawiorko@intel.com>
This commit is contained in:
Ben Ashbaugh
2020-09-01 02:16:18 -07:00
committed by GitHub
parent 11c3eb6610
commit e075026819
11 changed files with 495 additions and 126 deletions

View File

@@ -278,6 +278,19 @@ const char *GetDataVectorString( void *dataBuffer, size_t typeSize, size_t vecSi
return buffer;
}
const char *GetQueuePropertyName(cl_command_queue_properties property)
{
switch (property)
{
case CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE:
return "CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE";
case CL_QUEUE_PROFILING_ENABLE: return "CL_QUEUE_PROFILING_ENABLE";
case CL_QUEUE_ON_DEVICE: return "CL_QUEUE_ON_DEVICE";
case CL_QUEUE_ON_DEVICE_DEFAULT: return "CL_QUEUE_ON_DEVICE_DEFAULT";
default: return "(unknown)";
}
}
#ifndef MAX
#define MAX( _a, _b ) ((_a) > (_b) ? (_a) : (_b))
#endif