This fixes occurrences where the previous wrong specifier appears to
work in a typical 64-bit build, but causes a Wformat warning in 32-bit
builds.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
Fixes narrowing conversion build errors in test_common
Removing disable of narrowing errors in main CMakeLists.txt
and moving it down to specific test_conformance suite's
CMakeLists.txt where there are many more build errors revealed
from this fix.
Fixes a few simple issues under test_conformance in the process.
Contributes #787
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
---------
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
The computeinfo test already checks that the cl_khr_fp16 extension is
available before querying `CL_DEVICE_HALF_FP_CONFIG`, but never actually
made the `CL_DEVICE_HALF_FP_CONFIG` query.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
Even on the common code path (i.e., no error paths taken),
test_computeinfo failed to release its allocated memory, preventing a
clean run with LeakSanitizer.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
All of these warnings stem from printing `size_t` types, which should
be done using the `z` length modifier.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
The variable `config_size_ret` is only assigned to inside the `if`.
If the condition is false, we would read uninitialized data.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
In `os_helpers.cpp`, the preceding `if` already handles negative
values, so cast to unsigned.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
Remove unused variables throughout the code base and enable the
`-Wunused-variable` warning flag globally to prevent new unused
variable issues being introduced in the future.
This is mostly a non-functional change, with one exception:
- In `test_conformance/api/test_kernel_arg_info.cpp`, an error check
of the clGetDeviceInfo return value was added.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
* add basic test for cl_khr_pci_bus_info
* correctly use TEST_SKIPPED_ITSELF
Co-authored-by: Kévin Petit <kpet@free.fr>
* fix related usage of TEST_SKIPPED_ITSELF
Co-authored-by: Kévin Petit <kpet@free.fr>
Previously this file used the auto keyword to
declare a string. This can cause compilation
issues when used in a later function.
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
* Validate CL_DEVICE_LATEST_CONFORMANCE_VERSION_PASSED
Adding test to validate value returned from clGetDeviceInfo with
CL_DEVICE_LATEST_CONFORMANCE_VERSION_PASSED.
Fixes#993
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
* Fixes for formatting on computeinfo add tests
Fixes#993
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
* Tests requiring image support use runTestHarnessWithCheck
Removing special case for images in runTestHarness.
Fixes#710
* Remove imageSupportRequired argument
Tests which require image support now specify this while
calling runTestHarnessWithCheck.
Fixes#710
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
Basic conformance testing for the cl_khr_device_uuid extension. Checks
that the ID queries return the right sizes and that the returned IDs are
stable across two calls to clGetDeviceInfo. If device LUID validity is
true, also checks that one and only one bit is set in the device node
mask.
Signed-off-by: Einar Hov <einar.hov@arm.com>
* Enable -Werror for GCC/Clang builds
Fixes many of the errors this produces, and disables a handful that
didn't have solutions that were obvious (to me).
* Check for `-W*` flags empirically
* Remove cl_APPLE_fp64_basic_ops support
* Undo NAN conversion fix
* Add comments to warning override flags
* Remove unneeded STRINGIFY definition
* Fix tautological compare issue in basic
* Use ABS_ERROR macro in image tests
* Use fabs for ABS_ERROR macro
* Move ABS_ERROR definition to common header
Tests that the new queries work, and that what they return is consistent with
the information returned by the string-based queries.
Signed-off-by: Einar Hov <einar.hov@arm.com>
Currently capabilities with size_t type like CL_DEVICE_GLOBAL_VARIABLE_PREFERRED_TOTAL_SIZE
are printed as signed values for example:
CL_DEVICE_GLOBAL_VARIABLE_PREFERRED_TOTAL_SIZE == -881700864
The maintenance of the conformance tests is moving to Github.
This commit contains all the changes that have been done in
Gitlab since the first public release of the conformance tests.
Signed-off-by: Kevin Petit kevin.petit@arm.com