From 9d5dc202cb2a585915a16f1e6f756825a5b3e793 Mon Sep 17 00:00:00 2001 From: Jeremy Kemp Date: Wed, 11 Mar 2020 10:09:35 +0000 Subject: [PATCH] Updated the test to use get_device_cl_version (instead of check_opencl_version) (#527) (#672) Also changed the test so that any implementation supporting < 1.2 can skip the test. Uses format that @gwawiork has recently used to verify device version. --- test_conformance/printf/test_printf.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/test_conformance/printf/test_printf.cpp b/test_conformance/printf/test_printf.cpp index 16bb02c8..8d09d350 100644 --- a/test_conformance/printf/test_printf.cpp +++ b/test_conformance/printf/test_printf.cpp @@ -1029,11 +1029,12 @@ test_status InitCL( cl_device_id device ) PrintArch(); - - err = check_opencl_version(device,1,2); - if( err != CL_SUCCESS ) { - print_missing_feature(err,"printf"); - return TEST_FAIL; + auto version = get_device_cl_version(device); + auto expected_min_version = Version(1, 2); + if (version < expected_min_version) + { + version_expected_info("Test", expected_min_version.to_string().c_str(), version.to_string().c_str()); + return TEST_SKIP; } log_info( "Test binary built %s %s\n", __DATE__, __TIME__ );