Skip to content

Commit 59daec6

Browse files
Add support for cl_khr_external_memory_android_hardware_buffer and cl_khr_external_semaphore_dx_fence (#329)
* Add support for memory_ahb and semaphore_dx_fence * Retrigger CI * fixes CI (#330) If we want to build the OpenCL-ICD_Loader with CMAKE_C_EXTENSIONS=OFF then we should build this way for the OpenCL-ICD-Loader CI, also. * Add support for memory_ahb and semaphore_dx_fence * Retrigger CI * Remove whitespace --------- Co-authored-by: Ben Ashbaugh <ben.ashbaugh@intel.com>
1 parent 9b78d25 commit 59daec6

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

include/CL/opencl.hpp

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1572,6 +1572,9 @@ inline cl_int getInfoHelper(Func f, cl_uint name, T* param, int, typename T::cl_
15721572
F(cl_device_info, CL_DEVICE_SEMAPHORE_EXPORT_HANDLE_TYPES_KHR, cl::vector<cl_external_semaphore_handle_type_khr>) \
15731573
F(cl_semaphore_info_khr, CL_SEMAPHORE_EXPORT_HANDLE_TYPES_KHR, cl::vector<cl_external_semaphore_handle_type_khr>) \
15741574

1575+
#define CL_HPP_PARAM_NAME_CL_KHR_EXTERNAL_SEMAPHORE_DX_FENCE_EXT(F) \
1576+
F(cl_external_semaphore_handle_type_khr, CL_SEMAPHORE_HANDLE_D3D12_FENCE_KHR, void*) \
1577+
15751578
#define CL_HPP_PARAM_NAME_CL_KHR_EXTERNAL_SEMAPHORE_OPAQUE_FD_EXT(F) \
15761579
F(cl_external_semaphore_handle_type_khr, CL_SEMAPHORE_HANDLE_OPAQUE_FD_KHR, int) \
15771580

@@ -1721,6 +1724,9 @@ CL_HPP_PARAM_NAME_CL_KHR_EXTERNAL_MEMORY_(CL_HPP_DECLARE_PARAM_TRAITS_)
17211724
CL_HPP_PARAM_NAME_CL_KHR_EXTERNAL_SEMAPHORE_(CL_HPP_DECLARE_PARAM_TRAITS_)
17221725
#endif // cl_khr_external_semaphore
17231726

1727+
#if defined(cl_khr_external_semaphore_dx_fence)
1728+
CL_HPP_PARAM_NAME_CL_KHR_EXTERNAL_SEMAPHORE_DX_FENCE_EXT(CL_HPP_DECLARE_PARAM_TRAITS_)
1729+
#endif // cl_khr_external_semaphore_dx_fence
17241730
#if defined(cl_khr_external_semaphore_opaque_fd)
17251731
CL_HPP_PARAM_NAME_CL_KHR_EXTERNAL_SEMAPHORE_OPAQUE_FD_EXT(CL_HPP_DECLARE_PARAM_TRAITS_)
17261732
#endif // cl_khr_external_semaphore_opaque_fd
@@ -7531,6 +7537,9 @@ inline Kernel::Kernel(const Program& program, const char* name, cl_int* err)
75317537
enum class ExternalMemoryType : cl_external_memory_handle_type_khr
75327538
{
75337539
None = 0,
7540+
#ifdef cl_khr_external_memory_android_hardware_buffer
7541+
AndroidHardwareBuffer = CL_EXTERNAL_MEMORY_HANDLE_ANDROID_HARDWARE_BUFFER_KHR,
7542+
#endif // cl_khr_external_memory_android_hardware_buffer
75347543
#ifdef cl_khr_external_memory_opaque_fd
75357544
OpaqueFd = CL_EXTERNAL_MEMORY_HANDLE_OPAQUE_FD_KHR,
75367545
#endif // cl_khr_external_memory_opaque_fd
@@ -11245,6 +11254,9 @@ namespace compatibility {
1124511254
enum ExternalSemaphoreType : cl_external_semaphore_handle_type_khr
1124611255
{
1124711256
None = 0,
11257+
#ifdef cl_khr_external_semaphore_dx_fence
11258+
D3D12Fence = CL_SEMAPHORE_HANDLE_D3D12_FENCE_KHR,
11259+
#endif // cl_khr_external_semaphore_dx_fence
1124811260
#ifdef cl_khr_external_semaphore_opaque_fd
1124911261
OpaqueFd = CL_SEMAPHORE_HANDLE_OPAQUE_FD_KHR,
1125011262
#endif // cl_khr_external_semaphore_opaque_fd

0 commit comments

Comments
 (0)