Commit Graph

9 Commits

Author SHA1 Message Date
Jose Lopez
580fde7501 Replace unique_ptr for vectors in atomics_indexed_cases (#2557)
Use vectors instead of unique_ptr for buffers data
2025-10-28 08:55:41 -07:00
Ahmed Hesham
2fe382ec8a Migrate atomics suite to the new test registration framework (#2189)
Contributes to #2181
2024-12-13 16:33:56 +00:00
Sven van Haastregt
46fde8d051 atomics: fix memory leaks on error paths (#1732)
Before this change, `add_index_bin_test` would not release `cl_mem`
resources or `malloc`ed memory when encountering an error.  Fix by
using `clMemWrapper` and `std::unique_ptr` to automatically release
resources.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2023-08-29 09:13:03 -07:00
Sven van Haastregt
d223e46f20 atomics: Remove unused variable in atomic_add_index_bin (#1709)
Remove a variable that was set when an OpenCL API call failed, but
never read again.  Instead, return immediately upon failure.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2023-05-11 14:12:09 +01:00
Sven van Haastregt
c69f6eec47 [NFC] atomics: Remove set-but-unused "succeed" variables (#1517)
The "succeed" variables are never read and they don't seem to serve
any purpose that's not already provided by the "fail" variables.

In `add_index_bin_test` the "fail" variable is also set but unused,
but that may require an actual fix, so leaving that out of this
commit.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2022-09-30 11:41:19 +01:00
Sven van Haastregt
9bf6486352 [NFC] clang-format test_atomics (#1516)
Add some clang-format off/on comments to keep lists and kernel code
readable.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
2022-09-27 09:32:23 -07:00
ellnor01
a6809710ea Remove unnecessary cl_mem_flags casts (#1018)
* api, atomics: remove unnecessary cl_mem_flags casts

Instances in api, atomics, buffers and c11_atomics suites

Contributes #759

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>

* basic: remove unnecessary cl_mem_flags casts

Contributes #759

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>

* spir, thread_dimensions: remove unnecessary cl_mem_flags casts

Instances in spir, thread_dimensions and workgroups tests

Contributes #759

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>

* profiling, relationals: remove unnecessary cl_mem_flags casts

Includes relationals, profiling, muliple_device_context, integer_ops
tests

Contributes #759

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>

* clcpp: remove unnecessary cl_mem_flags casts

Contibutes #759

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>

* events, geometrics: remove unnecessary cl_mem_flags casts

Includes events, geometrics, gl and images tests

Contributes #759

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>

* commonfs, compiler: remove unnecessary cl_mem_flags casts

Includes cast removal in commonfs, compiler and device_partition tests

Fixes #759

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>

* Fix up formatting

Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com>
2020-10-19 13:56:02 +01:00
Ankit Goyal
4fbcd96e7f Remove "C" linkages (#781)
* Remove extern C linkages

* Update crc32 to cpp and remove extern C linkage
2020-05-20 14:16:19 +01:00
James Price
40f50d77a3 Rename test .c sources to .cpp where necessary (#604)
Remove hacks to force language from CMake files.

Closes KhronosGroup/OpenCL-CTS#25
2020-02-21 17:34:31 +00:00