| 394 | } |
| 395 | |
| 396 | static std::string getCommandQueuePropertyString(cl_command_queue_properties property) { |
| 397 | if (property == 0) { |
| 398 | return "0"; |
| 399 | } |
| 400 | |
| 401 | std::ostringstream ss; |
| 402 | while (property) { |
| 403 | if (property & CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE) { |
| 404 | ss << "CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE"; |
| 405 | property &= ~CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE; |
| 406 | } else if (property & CL_QUEUE_PROFILING_ENABLE) { |
| 407 | ss << "CL_QUEUE_PROFILING_ENABLE"; |
| 408 | property &= ~CL_QUEUE_PROFILING_ENABLE; |
| 409 | } else { |
| 410 | ss << "0x" << std::hex << (int)property; |
| 411 | property = 0; |
| 412 | } |
| 413 | if (property != 0) { |
| 414 | ss << '|'; |
| 415 | } |
| 416 | } |
| 417 | |
| 418 | return ss.str(); |
| 419 | } |
| 420 | |
| 421 | static std::string getQueuePropertyString(const cl_queue_properties* qprops) { |
| 422 | if (qprops == NULL) { |
no outgoing calls
no test coverage detected