Since GCC 13 some headers are no longer included transitively through
C++ Standard Library headers.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
According to work plan from issue #1058
Added new case `TYPE_MIXED_FORMAT_RANDOM` which focus on three factors:
-data before conversion flags - this is randomly generated ascii string
-randomly generated conversion flags - integer or floating point, for
each flag specific argument is generated
-data after conversion flags - this is randomly generated ascii string
Moreover, due to fact in case of `TYPE_MIXED_FORMAT_RANDOM` test is
generated on the fly, logging of negative result was extended.
We've had a couple of bugs inside mesa/rusticl processing %% correctly.
I've added those cases locally to make sure all corner cases are
properly handled.
According to work plan from issue #1058
Corrections to general test:
-removed duplication of separate tests for each element of
`PrintfTestType` vector, instead `doTest` procedure would iterate over
vector related to specific `PrintfTestType` automaticaly
-fixed procedure to assemble kernel source so it can accept only one
parameter of the function ( eg. `printf("%%");` )
-incorporated important modifications from #1940 to avoid expected
conflicts
-warnings fixes, minor corrections, clang format
Extension for string testing:
-special symbols
-nested symbols
-all ascii characters
-added new type of test `TYPE_FORMAT_STRING` to verify format string
only (according to request from the issue)
* Added cl_khr_fp16 support for test_relationals (issue #142, relationals)
* Added cl_khr_fp16 support for any and bitselect test cases (issue #142, relationals)
* correction related to automated travis build for macOS (issue #142, relationals)
* more corrections related to automated travis build for macOS (issue #142, relationals)
* Added few cosmetic corrections (issue #142, test_relationals)
* Added missing clang format
* Added corrections related to order of initialization
* Added corrections due to code review (issue #142, relationals)
* Correction for prev commit
* Added subnormals related condition for test verification (issue #142, relationals)
* Added indexing correction due to code review
* Replaced hardcoded iteration limit (issue #142, relationals)
* Added support to test half floats with printf calls (issue #142, printf)
* Added corrections related to rounding and casting halfs (issue #142, printf)
* Reusing similar function (issue #142, printf)
* Corrected path without cl_khr_fp16 support (issue #142, printf)
* Cosmetic fix for order of vector tests (issue #142, printf)
* Added correction related to vendor test review (issue #142, printf)
`CMAKE_CXX_STANDARD` is already set in the top-level CMakeLists.txt
file, so there is no need to have it repeated for individual modules.
Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
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>
* Using helper functions for clCreateKernel
Uses of clCreateKernel following create program helper
functions, have been incorporated into
create_single_kernel_helper when suitable.
Contributes #31
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
* Skip tests using clCompileProgram in offline mode
Contributes #31
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
* Using type wrappers when using kernel helper functions
Also includes fix for windows build
Fixes#31
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
* Remove clReleaseKernel for wrapped kernel
Fixes#31
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
* Moved float tests that expect limits into their own sub-test.
These are harder to test generically on the CPU so have them be their own test which will retain hard-coded reference results.
* Remove unused variable.
* Switched reference result type from (char**) to (vector::const char*)
* printf: generate reference results where possible #673#675
The reference results had two issues:
- They did not take into account the rounding mode of the device.
- Scientific notation results did not have trailing zero's, meaning that the exponent could be a single digit, despite the requirement being at least two digits.
This change introduces runtime generated reference results for types with numerical representations (float, int, hex, etc) where a direct mapping to standard C99 (sn)printf is possible to execute on the CPU.
* Trim leading zeroes from the exponent when verifying result #675.
There is no limit on how many leading zeros may be in the exponent, so strip them all.
* Switched to using get_default_rounding_mode.
(Patch2)
A number of tests have got their own code for checking the presence of
extensions. This change replaces that code with is_extension_available
function.
Contributes to #627
Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
Change-Id: I17e007e5ad009e522c5006c42537bf1170550a6f
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.
Moved all duplicate 'PrintArch' functions to testHarness.c
Replaced sysctl system call used in 'PrintArch' function with uname
system call
Signed-off-by: bhargavdas <bhargav_das@mentor.com>
Update testHarness.c
In all these cases, the new entrypoint is not necessary. These
changes enable the tests to work or are a necessary step to get
the tests to work on an OpenCL 1.2 implementation.
While this may not be the final approach we want to solve this
specific compatibility issue, it also has the nice property of
reducing the diff with cl12_trunk until we merge.
Signed-off-by: Kévin Petit <kpet@free.fr>
The cl_arm_printf extension uses a call-back to tell the user-code
that some printf output has appeared from the execution of the CL
kernel.
The extsiting Printf tests assume output to stdout.
This change adds code to detect the cl_arm_printf extension, and an
implementation of the callback code to write to stdout.
Also fix a couple of formatting errors and don't "poll" when waiting
for events.
Signed-off-by: Mats Petersson <mats.petersson@arm.com>
Parallel printf tests fail because they use the same file /tmp/tmpfile
to capture OpenCL kernel outputs. This patch solves this problem by
using a unique file for each process.
Some of the setup functionality is already there in the test harness, so
use that and remove the duplicated code from within the suite.
Signed-off-by: Radek Szymanski <radek.szymanski@arm.com>
Function verifyOutputBuffer returns non-zero value in case of mismatch.
Return value 'false' means some mismatches are treated as matches. This
commit fix this problem.
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