Skip to content

Commit

Permalink
Corrections related to code review
Browse files Browse the repository at this point in the history
  • Loading branch information
shajder committed Apr 11, 2024
1 parent 5f0cb00 commit 1dfd7fd
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -604,16 +604,16 @@ int test_semaphores_queries(cl_device_id deviceID, cl_context context,
cl_device_id capable_device = deviceID;

err = clGetDeviceIDs(platform_id, CL_DEVICE_TYPE_ALL, num_devices,
&devices[0], nullptr);
devices.data(), nullptr);
test_error(err, "clGetDeviceIDs failed");

// if possible use device other than the one from harness
for (size_t i = 0; i < devices.size(); ++i)
for (auto device : devices)
{
if (deviceID != devices[i]
if (deviceID != device
&& is_extension_available(capable_device, "cl_khr_semaphore"))
{
capable_device = devices[i];
capable_device = device;
break;
}
}
Expand Down

0 comments on commit 1dfd7fd

Please sign in to comment.