mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-26 00:39:03 +00:00
Global variable gDeviceType correctly set (#611)
Add gDeviceType set on kernel_read_write tests(image_streams) as the device type affects the way validation is performed in the test. Signed-off-by: John Kesapides <john.kesapides@arm.com>
This commit is contained in:
@@ -253,7 +253,7 @@ int runTestHarnessWithCheck( int argc, const char *argv[], int testNum, test_def
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
gDeviceType = device_type;
|
|
||||||
|
|
||||||
switch (device_type)
|
switch (device_type)
|
||||||
{
|
{
|
||||||
@@ -344,6 +344,13 @@ int runTestHarnessWithCheck( int argc, const char *argv[], int testNum, test_def
|
|||||||
|
|
||||||
device = devices[choosen_device_index];
|
device = devices[choosen_device_index];
|
||||||
|
|
||||||
|
err = clGetDeviceInfo( device, CL_DEVICE_TYPE, sizeof(gDeviceType), &gDeviceType, NULL );
|
||||||
|
if( err )
|
||||||
|
{
|
||||||
|
print_error( err, "Unable to get device type" );
|
||||||
|
return TEST_FAIL;
|
||||||
|
}
|
||||||
|
|
||||||
if( printDeviceHeader( device ) != CL_SUCCESS )
|
if( printDeviceHeader( device ) != CL_SUCCESS )
|
||||||
{
|
{
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
|
|||||||
Reference in New Issue
Block a user