Commit Graph

1688 Commits

Author SHA1 Message Date
Kévin Petit
e96edaef8b Require C++17 (#2356)
This enables many useful newer C++ features. C++17 is already required
by many components of the Khronos ecosystem.

Signed-off-by: Kevin Petit <kevin.petit@arm.com>
v2025-04-14-00
2025-04-08 09:50:33 -07:00
Sven van Haastregt
0abec2f49a spirv_new: remove invalid Aligned 0 decorations (#2360)
After https://github.com/KhronosGroup/SPIRV-Tools/pull/6027 spirv-val is
now rejecting `Aligned 0` Memory Operands. This causes the spirv_new
test binary to no longer build with a recent SPIRV-Tools version.

Mechanically remove all occurrences of `Aligned 0` in the SPIR-V
assembly files.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2025-04-08 17:49:00 +01:00
Grzegorz Wawiorko
051b82b7e9 SPIR-V tests for scalar printf - fix for Windows OS (#2358) 2025-04-04 08:52:05 -07:00
Grzegorz Wawiorko
42b4bca510 Fix test_printf - any nan format is allowed by OpenCL C spec (#2298)
OpenCL C says that printing nan is implementation-defined for
floating-point numbers -
https://registry.khronos.org/OpenCL/specs/3.0-unified/html/OpenCL_C.html#printf-format-string
2025-04-01 13:44:39 -07:00
Michael Rizkalla
5930d45fc6 Refactor clCopyImage and clFillImage tests (#2283)
This change mainly extends `clFillImage` and `clCopyImage` test function
to include memory flags to be used during creating the image instead of
hard-coding these values. The memory flags are also different parameters
for source and destination images in `clCopyImage` tests.

---------

Signed-off-by: Michael Rizkalla <michael.rizkalla@arm.com>
2025-04-01 09:53:37 -07:00
Sreelakshmi Haridas Maruthur
78bd3ddece allocations: Scale number of work-items in relation to input size (#2336)
Make the number of work-items proportional to size of the allocation so
we launch more work-items and do less work per work-item as buffer sizes
go up with device capabilities.

To test:
test_allocations multiple 5 buffer
test_allocations single 5 buffer
2025-04-01 09:53:21 -07:00
Grzegorz Wawiorko
a429ce771e Test printf - set more precisely printing floating point numbers (#2299)
We noticed such issue 
expected: ^(K{C, -30304.8, -22634.574219, 24476.882812, E4929EC2,
1467582223, 96vL.+
got: ^(K{C, -30304.8, -22634.574219, 24476.882813, E4929EC2, 1467582223,
96vL.+
The input value is 24476.882812 and cannot be precisely represented as a
single-floating point, so compilers are allowed to round it to the
nearest representable value. In this case, the closest representable
value to 24476.882812 is 24476.8828125, which rounds to 24476.882813.
Even some versions of MSVC prints that value as 24476.882813 and some
24476.882812 : https://godbolt.org/z/5GhEf8KPT
The proposal is to set precisely how many number should be displayed to
avoid rounding.
2025-04-01 09:52:19 -07:00
Marcin Hajder
4e00778b93 Modernization of semaphores_negative_create_invalid_device related to creating sub-devices (#2307)
Due to the improvements developed during work on #2237 with @bashbaug
2025-04-01 08:47:59 -07:00
Marcin Hajder
88953edf6c Modernization of semaphores_negative_create_multi_device_property related to creating sub-devices (#2306)
Due to the improvements developed during work on #2237 with @bashbaug
2025-04-01 08:47:27 -07:00
Marcin Hajder
004bc4a82d Cleanup corrections for get_program_info_mult_devices test (#2305) 2025-04-01 08:46:18 -07:00
Sven van Haastregt
b6924adfb2 basic: fix Wformat warnings (#2343)
Fix all `-Wformat` warnings in the basic test suite, and re-enable the
warning.

---------

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2025-03-25 09:45:18 -07:00
Marcin Hajder
1cbb548e27 Added support to run the CTS with Vulkan validation layers (#2246)
Fixes #2116 according to task description.

As approved 25Mar25
2025-03-25 08:43:28 -07:00
Marcin Hajder
81f33190e2 Added test to verify program queries after recompiling and relinking (#2272)
Fixes #2163 according to issue description

As approved 25Mar25
2025-03-25 08:41:04 -07:00
Michael Rizkalla
e36da9798e Migrate integer_ops suite to the new test registration framework (#2332)
Contributes to https://github.com/KhronosGroup/OpenCL-CTS/issues/2181.

Signed-off-by: Michael Rizkalla <michael.rizkalla@arm.com>
2025-03-23 15:12:34 +00:00
Ahmed Hesham
a9507ce33f Migrate images suite to the new test registration framework (#2328)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-23 15:02:29 +00:00
Michal Babej
36178cf6e3 add tests for cl_ext_buffer_device_address (#2192) 2025-03-19 14:08:17 -07:00
Ahmed Hesham
e88e5be93e Migrate basic suite to the new test registration framework (#2316)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-18 17:32:58 +00:00
Ahmed Hesham
b39eff86c5 Migrate math_brute_force to the new test registration framework (#2327)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-18 17:25:14 +00:00
Ahmed Hesham
11db5e5d62 Migrate multiple_device_context suite to the new test registration framework (#2325)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-18 17:22:11 +00:00
Ahmed Hesham
e52f6a732b Migrate conversions suite to the new test registration framework (#2322)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-18 17:15:28 +00:00
Michael Rizkalla
ac38405a62 Migrate geometrics suite to the new test registration framework (#2335)
Contributes to https://github.com/KhronosGroup/OpenCL-CTS/issues/2181.

Signed-off-by: Michael Rizkalla <michael.rizkalla@arm.com>
2025-03-18 17:13:35 +00:00
Michael Rizkalla
7cd13e1e93 Migrate generic_address_space suite to the new test registration framework (#2333)
Contributes to https://github.com/KhronosGroup/OpenCL-CTS/issues/2181.

Signed-off-by: Michael Rizkalla <michael.rizkalla@arm.com>
2025-03-18 17:11:43 +00:00
Ahmed Hesham
2131aff0e9 Migrate compiler suite to the new test registration framework (#2319)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-18 17:10:21 +00:00
Ahmed Hesham
d4c292ed46 Fix broken CI on MacOS (#2341)
LunarG has changed the SDK file hosted for MacOS v1.3.275.0 from a .zip
file to a .dmg file with the old hyperlink transparently redirecting to
the new one.

The script expects a .zip archive so it fails when it downloads a .dmg
file.

Bump the Vulkan SDK version to 1.4.309.0, which is the latest version
and is provided as a .zip archive.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-18 09:04:14 -07:00
Starla Huang
395648cfef Use max work item size instead (#2294)
The test is using CL_DEVICE_MAX_WORK_GROUP_SIZE as first dimension of
local work size. But it can be bigger than the first dimension of
CL_DEVICE_MAX_WORK_ITEM_SIZEs which results in failure.

This patch corrects it to query and use the first dimension of
CL_DEVICE_MAX_WORK_ITEM_SIZES instead.

Signed-off-by: Xing Huang <xing.huang@arm.com>
2025-03-18 09:03:13 -07:00
Sven van Haastregt
b9301d1ae8 basic: fix -Wformat-security warnings (#2284)
Fix warnings such as:

test_vloadstore.cpp:330:49: error: format string is not a string literal
(potentially insecure)

There were no security issues here as the format string arguments do not
contain any conversion specifiers and are never written to. Make that
latter fact explicit to avoid the warnings.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2025-03-18 09:02:31 -07:00
Ahmed
d38b8b4ae8 Change relaxed exp exp2 embedded error to 4 + floor(fabs(2x)) (#2326)
Reflects the changes to the specification:
https://github.com/KhronosGroup/OpenCL-Docs/pull/1318

Relaxed embedded exp and exp2 ulps will be 4 + floor(fabs(2 * x)).

Reciprocal and divide are unchanged because the code already handles the
embedded profile case, see unary_float.c and binary_operator_float.c.

---------

Co-authored-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2025-03-18 08:55:27 -07:00
Kévin Petit
bb604702a5 Migrate workgroups suite to the new test registration framework (#2308)
Contributes to #2181

Signed-off-by: Kévin Petit <kpet@free.fr>
2025-03-11 22:00:38 +00:00
Ahmed Hesham
641ffeaa67 Migrate half suite to the new test registration framework (#2329)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-11 22:00:23 +00:00
Ahmed Hesham
ba95285a0e Migrate contractions suite to the new test registration framework (#2321)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-11 21:58:52 +00:00
Ahmed Hesham
c4fa48db05 Migrate events suite to the new test registration framework (#2324)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-11 21:57:59 +00:00
Ahmed Hesham
bb331c2c92 Migrate device_execution suite to the new test registration framework (#2323)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-11 21:54:22 +00:00
Ahmed Hesham
671ea7b286 Migrate computeinfo suite to the new test registration framework (#2320)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-11 21:52:28 +00:00
Kévin Petit
13b82d1833 Migrate non_uniform_work_group suite to the new test registration framework (#2317)
Contributes to #2181

Signed-off-by: Kévin Petit <kpet@free.fr>
2025-03-11 21:48:14 +00:00
Kévin Petit
132ba21a3c Migrate mem_host_flags suite to the new test registration framework (#2314)
Contributes to #2181

Signed-off-by: Kévin Petit <kpet@free.fr>
2025-03-11 21:47:58 +00:00
Kévin Petit
c4179d0f6a Migrate thread_dimensions suite to the new test registration framework (#2309)
Contributes to #2181

Signed-off-by: Kévin Petit <kpet@free.fr>
2025-03-11 21:46:38 +00:00
Kévin Petit
3a275fe81b Always enable beta extensions (#2330)
`CL_ENABLE_BETA_EXTENSIONS` was just introduced in
https://github.com/KhronosGroup/OpenCL-Headers/pull/276
to guard provisional and other experimental extensions. The CTS
currently assumes
all definitions are always present.

Signed-off-by: Kevin Petit <kevin.petit@arm.com>
2025-03-11 11:40:29 -07:00
Kévin Petit
30f9a5eb21 Remove .gitattributes (#2310)
We don't use git lfs. We have no .7z files in the repo.

Signed-off-by: Kévin Petit <kpet@free.fr>
2025-03-10 22:16:21 -07:00
Ahmed Hesham
2d0fda0179 Migrate c11_atomics suite the new test registration framework (#2318)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-10 09:55:24 +00:00
Ahmed Hesham
fbeebac9d5 Migrate buffers suite to the new test registration framework (#2315)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-09 09:59:01 +00:00
Ahmed Hesham
3f7774b089 Migrate subgroups suite to the new test registration framework (#2313)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-09 09:53:47 +00:00
Ahmed Hesham
aed6c3a214 Migrate relationals suite to the new test registration framework (#2312)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-09 09:49:24 +00:00
Ahmed Hesham
6eb1aa1d0a Migrate printf suite to the new test registration framework (#2311)
Contributes to #2181.

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-09 09:44:59 +00:00
Ahmed Hesham
5b47d4b19f Migrate pipes suite to the new test registration framework (#2302)
Contributes to #2181

Signed-off-by: Ahmed Hesham <ahmed.hesham@arm.com>
2025-03-09 09:42:10 +00:00
Ahmed Hesham
521d067083 Migrate device_partition suite to the new test registration framework (#2301)
Contributes to #2181
2025-03-08 22:37:04 +00:00
Romaric Jodin
11db332281 fix error message in work_item_functions_out_of_range (#2303)
The value printed in the error message is not the correct one (used in
the comparison statement)
2025-03-07 23:43:00 +00:00
Ben Ashbaugh
637deb0011 add missing Float16 capability (#2304)
A recent improvement to the SPIR-V validator added checks to ensure the
**Float16** capability is declared when directly operating on fp16
values, which identified issues in one of our SPIR-V test files. This PR
fixes the SPIR-V files to add the missing capability.
2025-03-07 10:08:58 -08:00
Ben Ashbaugh
6a36bd9d5c add SPIR-V 1.6 testing for UniformDecoration decorations (#2254)
Adds a basic test for the SPIR-V 1.6 UniformDecoration decorations.
Specifically:

* Tests both the Uniform and UniformId decorations.
* Tests the decorations on constants, function parameters, and
variables.
2025-03-05 08:29:26 -08:00
Michael Rizkalla
9a5041a25b Fix inconsistent variable name in REGISTER_TEST and REQUIRE_EXTENSION (#2296)
Both `REGISTER_TEST` and `REQUIRE_EXTENSION` expect cl_device_id
variable but the variable name is inconsistent which makes both macros
unusable together.

This change renames `deviceID` in `REQUIRE_EXTENSION` to `device` to be
consistent with `REGISTER_TEST`.

Signed-off-by: Michael Rizkalla <michael.rizkalla@arm.com>
2025-03-04 16:53:50 -08:00
Sven van Haastregt
733cc78c39 spirv_new: ensure int64 printf test uses 64 bits (#2295)
The `extinst_printf_operands_scalar_int64` test could fail on 32-bit
platforms with `CL_INVALID_ARG_SIZE`, because the helper function was
not guaranteed to be instantiated using a 64-bit integer template type.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2025-03-04 16:53:25 -08:00