mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
Migrate computeinfo suite to the new test registration framework (#2320)
Contributes to #2181. Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
This commit is contained in:
@@ -21,10 +21,9 @@
|
||||
#include "harness/testHarness.h"
|
||||
#include "harness/deviceInfo.h"
|
||||
|
||||
int test_pci_bus_info(cl_device_id deviceID, cl_context context,
|
||||
cl_command_queue ignoreQueue, int num_elements)
|
||||
REGISTER_TEST(pci_bus_info)
|
||||
{
|
||||
if (!is_extension_available(deviceID, "cl_khr_pci_bus_info"))
|
||||
if (!is_extension_available(device, "cl_khr_pci_bus_info"))
|
||||
{
|
||||
log_info("cl_khr_pci_bus_info not supported. Skipping test...\n");
|
||||
return TEST_SKIPPED_ITSELF;
|
||||
@@ -35,14 +34,14 @@ int test_pci_bus_info(cl_device_id deviceID, cl_context context,
|
||||
cl_device_pci_bus_info_khr info;
|
||||
|
||||
size_t size_ret;
|
||||
error = clGetDeviceInfo(deviceID, CL_DEVICE_PCI_BUS_INFO_KHR, 0, NULL,
|
||||
&size_ret);
|
||||
error =
|
||||
clGetDeviceInfo(device, CL_DEVICE_PCI_BUS_INFO_KHR, 0, NULL, &size_ret);
|
||||
test_error(error, "Unable to query CL_DEVICE_PCI_BUS_INFO_KHR size");
|
||||
test_assert_error(
|
||||
size_ret == sizeof(info),
|
||||
"Query for CL_DEVICE_PCI_BUS_INFO_KHR returned an unexpected size");
|
||||
|
||||
error = clGetDeviceInfo(deviceID, CL_DEVICE_PCI_BUS_INFO_KHR, sizeof(info),
|
||||
error = clGetDeviceInfo(device, CL_DEVICE_PCI_BUS_INFO_KHR, sizeof(info),
|
||||
&info, NULL);
|
||||
test_error(error, "Unable to query CL_DEVICE_PCI_BUS_INFO_KHR");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user