Remove the `CREATE_OPENCL_SEMAPHORE` macro and use derived class
instantiations of the `clExternalSemaphore` class, rather than base
pointers to derived class objects.
Remove the default argument for `queryParamName` in
`check_external_semaphore_handle_type()`.
Move `check_external_semaphore_handle_type()` checks to constructors of
`clExternalImportableSemaphore` and `clExternalExportableSemaphore`,
rather than manually making the check before creating an external
semaphore.
---------
Signed-off-by: Gorazd Sumkovski <gorazd.sumkovski@arm.com>
Co-authored-by: Kévin Petit <kpet@free.fr>
Co-authored-by: Kevin Petit <kevin.petit@arm.com>
Support for optimally-tiled images and tiling inference in general is
implementation-defined. It should not be relied upon in the CTS.
Also build the code base as C++17 for std::optional. Many Khronos
projects are now using C++17 and the transition in the CTS is IMO
overdue.
Signed-off-by: Kevin Petit <kevin.petit@arm.com>
Except for SYNC_FD, current implementation doesn't import exported
OpenCL semaphore in Vulkan and ends up doing signal and wait on
essentially two unrelated semaphores (one created in OpenCL and one in
Vulkan).
Since OpenCL exports the semaphore, import that in Vulkan to perform
signal/wait on the same underlying payload.
* Updated semaphore tests to use clSemaphoreReImportSyncFdKHR.
Additionally updated common semaphore code to handle spec updates
that restrict simultaneous importing/exporting of handles.
* Fix build issues on CI
* gcc build issues
* Make clReImportSemaphoreSyncFdKHR a required API
call if cl_khr_external_semaphore_sync_fd is present.
* Implement signal and wait for all semaphore types.
* Added support for SYNC_FD and other handle types
* Fix consistency test
Deleted test cases that are no longer testable
according to the spec.
* Fix multi-import tests
-Delete obsolete code relating to offsets
-Propagate dedicated memory change
* Fix error handling
Some subtests did not fail on incorrect result.
Changes to macros to fail, so this does not occur
again.
* Delete invalid test cases
Test cases are not related to this extension.
* External memory test
Add support for any handle type supported by
the platform.
Change-Id: I6765fde5e7929988f49bfbf2df2f41d5263b6abc
* Update multi-import tests to use new semaphore types
* Fix formatting
* Addressed review comments. Deleted VULKAN_EXTERNAL_SEMAPHORE_HANDLE_TYPE_OPAQUE_WIN32_NT_KMT as it appears to be redundant.
* Vulkan: Fix descriptor sets
Use descriptor set arrays when programming
arrays for compute shader.
Change-Id: Idabab775a256a223660eb7a850e26f290453659e
* Vulkan: Fix queue propertyies
Transfer bit for queue family is not required
to be reported by the implementation, it is
implicit for compute.
Change-Id: I7424b00e25e35145433dd74b0b4dfe7eeeaf98c8
* Vulkan: Allow implementation to choose dedicated memory
Dedicated vs non-dedicated memory must be queried by
the app. Implementations are not required to support
exportable non-dedicated memory.
Change-Id: Idbc46ace1be20f61d1b58b34756f6d79a7745911
* Fix formatting
Auto-generated formatting fix
* Fix bug in dedicated memory.
* Add check for if OpenCL assumes linear tiling
Change-Id: Idd2e24d9d69e1fbc3ccb4a279067533104185332
* Changed macro name to reflect spec
CL_DEVICE_EXTERNAL_MEMORY_IMPORT_ASSUME_LINEAR_HANDLE_TYPES_KHR to
CL_DEVICE_EXTERNAL_MEMORY_IMPORT_ASSUME_LINEAR_IMAGES_HANDLE_TYPES_KHR
Also changed some functions to not use the KHR variants.
---------
Co-authored-by: Joshua Kelly <joshkell@qti.qualcomm.com>
* Add external semaphore tests.
Added basic test to check the functionality of cl_ext_external_semaphore_test extension.
Tests rely on Vulkan API as the producer of the external semaphore functionality. The
Vulkan wrapper has been copied from the Vulkan CTS tests and minor changes have been
introduced. A separate copy of the Vulkan wrapper is for breaking any dependencies
between different CTS modules and thus make the build system simpler.
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Fix clang-format
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Move vulkan wrapper to a separate library.
Vulkan wrapper is extracted as a separate module and can be used in different
CTS tests as a shared library.
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Add cl_ext_external_samaphore tests based on cl_khr_semaphore tests.
Added cl_khr_semaphore adjusted to creating semaphores in Vulkan context
and importing them through export semaphore functionality in OpenCL
(cl_ext_external_samaphore).
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Cleanup.
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Fix build issues.
* Add missing directories for build cl_ext_external_semaphore.
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Set Vulkan lib directory.
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Change extension directory name.
Changed extensions directory name from cl_ext_external_semaphore to cl_khr_external_semaphore.
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
* Remove unneeded compile options.
Removed VK_USE_PLATFORM_WIN32_KHR option from cl_khr_external_semaphore
compilation arguments.
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>
---------
Signed-off-by: Paweł Jastrzębski <p.k.jastrzebski@gmail.com>