rknn-toolkit2-v2.1.0-2024-08-08
/
rknpu2
/examples
/3rdparty
/opencl
/libopencl-stub
/include
/CL
/cl_ext_intel.h
/******************************************************************************* | |
* Copyright (c) 2008-2020 The Khronos Group Inc. | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software | |
* distributed under the License is distributed on an "AS IS" BASIS, | |
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
* See the License for the specific language governing permissions and | |
* limitations under the License. | |
* | |
******************************************************************************/ | |
/*****************************************************************************\ | |
Copyright (c) 2013-2020 Intel Corporation All Rights Reserved. | |
THESE MATERIALS ARE PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | |
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | |
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | |
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR ITS | |
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, | |
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, | |
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR | |
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY | |
OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR TORT (INCLUDING | |
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THESE | |
MATERIALS, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | |
File Name: cl_ext_intel.h | |
Abstract: | |
Notes: | |
\*****************************************************************************/ | |
extern "C" { | |
/*************************************** | |
* cl_intel_thread_local_exec extension * | |
****************************************/ | |
/*********************************************** | |
* cl_intel_device_partition_by_names extension * | |
************************************************/ | |
/************************************************ | |
* cl_intel_accelerator extension * | |
* cl_intel_motion_estimation extension * | |
* cl_intel_advanced_motion_estimation extension * | |
*************************************************/ | |
typedef struct _cl_accelerator_intel* cl_accelerator_intel; | |
typedef cl_uint cl_accelerator_type_intel; | |
typedef cl_uint cl_accelerator_info_intel; | |
typedef struct _cl_motion_estimation_desc_intel { | |
cl_uint mb_block_type; | |
cl_uint subpixel_mode; | |
cl_uint sad_adjust_mode; | |
cl_uint search_path_type; | |
} cl_motion_estimation_desc_intel; | |
/* error codes */ | |
/* cl_accelerator_type_intel */ | |
/* cl_accelerator_info_intel */ | |
/* cl_motion_detect_desc_intel flags */ | |
/* cl_device_info */ | |
extern CL_API_ENTRY cl_accelerator_intel CL_API_CALL | |
clCreateAcceleratorINTEL( | |
cl_context context, | |
cl_accelerator_type_intel accelerator_type, | |
size_t descriptor_size, | |
const void* descriptor, | |
cl_int* errcode_ret) CL_EXT_SUFFIX__VERSION_1_2; | |
typedef CL_API_ENTRY cl_accelerator_intel (CL_API_CALL *clCreateAcceleratorINTEL_fn)( | |
cl_context context, | |
cl_accelerator_type_intel accelerator_type, | |
size_t descriptor_size, | |
const void* descriptor, | |
cl_int* errcode_ret) CL_EXT_SUFFIX__VERSION_1_2; | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clGetAcceleratorInfoINTEL( | |
cl_accelerator_intel accelerator, | |
cl_accelerator_info_intel param_name, | |
size_t param_value_size, | |
void* param_value, | |
size_t* param_value_size_ret) CL_EXT_SUFFIX__VERSION_1_2; | |
typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetAcceleratorInfoINTEL_fn)( | |
cl_accelerator_intel accelerator, | |
cl_accelerator_info_intel param_name, | |
size_t param_value_size, | |
void* param_value, | |
size_t* param_value_size_ret) CL_EXT_SUFFIX__VERSION_1_2; | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clRetainAcceleratorINTEL( | |
cl_accelerator_intel accelerator) CL_EXT_SUFFIX__VERSION_1_2; | |
typedef CL_API_ENTRY cl_int (CL_API_CALL *clRetainAcceleratorINTEL_fn)( | |
cl_accelerator_intel accelerator) CL_EXT_SUFFIX__VERSION_1_2; | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clReleaseAcceleratorINTEL( | |
cl_accelerator_intel accelerator) CL_EXT_SUFFIX__VERSION_1_2; | |
typedef CL_API_ENTRY cl_int (CL_API_CALL *clReleaseAcceleratorINTEL_fn)( | |
cl_accelerator_intel accelerator) CL_EXT_SUFFIX__VERSION_1_2; | |
/****************************************** | |
* cl_intel_simultaneous_sharing extension * | |
*******************************************/ | |
/*********************************** | |
* cl_intel_egl_image_yuv extension * | |
************************************/ | |
/******************************** | |
* cl_intel_packed_yuv extension * | |
*********************************/ | |
/******************************************** | |
* cl_intel_required_subgroup_size extension * | |
*********************************************/ | |
/**************************************** | |
* cl_intel_driver_diagnostics extension * | |
*****************************************/ | |
typedef cl_uint cl_diagnostics_verbose_level; | |
/******************************** | |
* cl_intel_planar_yuv extension * | |
*********************************/ | |
/******************************************************* | |
* cl_intel_device_side_avc_motion_estimation extension * | |
********************************************************/ | |
/******************************************* | |
* cl_intel_unified_shared_memory extension * | |
********************************************/ | |
/* These APIs are in sync with Revision O of the cl_intel_unified_shared_memory spec! */ | |
/* cl_device_info */ | |
typedef cl_bitfield cl_device_unified_shared_memory_capabilities_intel; | |
/* cl_device_unified_shared_memory_capabilities_intel - bitfield */ | |
typedef cl_properties cl_mem_properties_intel; | |
/* cl_mem_properties_intel */ | |
typedef cl_bitfield cl_mem_alloc_flags_intel; | |
/* cl_mem_alloc_flags_intel - bitfield */ | |
typedef cl_uint cl_mem_info_intel; | |
/* cl_mem_alloc_info_intel */ | |
/* Enum values 0x419E-0x419F are reserved for future queries. */ | |
typedef cl_uint cl_unified_shared_memory_type_intel; | |
/* cl_unified_shared_memory_type_intel */ | |
typedef cl_uint cl_mem_advice_intel; | |
/* cl_mem_advice_intel */ | |
/* Enum values 0x4208-0x420F are reserved for future memory advices. */ | |
/* cl_kernel_exec_info */ | |
/* cl_command_type */ | |
extern CL_API_ENTRY void* CL_API_CALL | |
clHostMemAllocINTEL( | |
cl_context context, | |
const cl_mem_properties_intel* properties, | |
size_t size, | |
cl_uint alignment, | |
cl_int* errcode_ret); | |
typedef CL_API_ENTRY void* (CL_API_CALL * | |
clHostMemAllocINTEL_fn)( | |
cl_context context, | |
const cl_mem_properties_intel* properties, | |
size_t size, | |
cl_uint alignment, | |
cl_int* errcode_ret); | |
extern CL_API_ENTRY void* CL_API_CALL | |
clDeviceMemAllocINTEL( | |
cl_context context, | |
cl_device_id device, | |
const cl_mem_properties_intel* properties, | |
size_t size, | |
cl_uint alignment, | |
cl_int* errcode_ret); | |
typedef CL_API_ENTRY void* (CL_API_CALL * | |
clDeviceMemAllocINTEL_fn)( | |
cl_context context, | |
cl_device_id device, | |
const cl_mem_properties_intel* properties, | |
size_t size, | |
cl_uint alignment, | |
cl_int* errcode_ret); | |
extern CL_API_ENTRY void* CL_API_CALL | |
clSharedMemAllocINTEL( | |
cl_context context, | |
cl_device_id device, | |
const cl_mem_properties_intel* properties, | |
size_t size, | |
cl_uint alignment, | |
cl_int* errcode_ret); | |
typedef CL_API_ENTRY void* (CL_API_CALL * | |
clSharedMemAllocINTEL_fn)( | |
cl_context context, | |
cl_device_id device, | |
const cl_mem_properties_intel* properties, | |
size_t size, | |
cl_uint alignment, | |
cl_int* errcode_ret); | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clMemFreeINTEL( | |
cl_context context, | |
void* ptr); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clMemFreeINTEL_fn)( | |
cl_context context, | |
void* ptr); | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clGetMemAllocInfoINTEL( | |
cl_context context, | |
const void* ptr, | |
cl_mem_info_intel param_name, | |
size_t param_value_size, | |
void* param_value, | |
size_t* param_value_size_ret); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clGetMemAllocInfoINTEL_fn)( | |
cl_context context, | |
const void* ptr, | |
cl_mem_info_intel param_name, | |
size_t param_value_size, | |
void* param_value, | |
size_t* param_value_size_ret); | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clSetKernelArgMemPointerINTEL( | |
cl_kernel kernel, | |
cl_uint arg_index, | |
const void* arg_value); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clSetKernelArgMemPointerINTEL_fn)( | |
cl_kernel kernel, | |
cl_uint arg_index, | |
const void* arg_value); | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clEnqueueMemsetINTEL( /* Deprecated */ | |
cl_command_queue command_queue, | |
void* dst_ptr, | |
cl_int value, | |
size_t size, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clEnqueueMemsetINTEL_fn)( /* Deprecated */ | |
cl_command_queue command_queue, | |
void* dst_ptr, | |
cl_int value, | |
size_t size, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clEnqueueMemFillINTEL( | |
cl_command_queue command_queue, | |
void* dst_ptr, | |
const void* pattern, | |
size_t pattern_size, | |
size_t size, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clEnqueueMemFillINTEL_fn)( | |
cl_command_queue command_queue, | |
void* dst_ptr, | |
const void* pattern, | |
size_t pattern_size, | |
size_t size, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clEnqueueMemcpyINTEL( | |
cl_command_queue command_queue, | |
cl_bool blocking, | |
void* dst_ptr, | |
const void* src_ptr, | |
size_t size, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clEnqueueMemcpyINTEL_fn)( | |
cl_command_queue command_queue, | |
cl_bool blocking, | |
void* dst_ptr, | |
const void* src_ptr, | |
size_t size, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
/* Because these APIs use cl_mem_migration_flags, they require | |
OpenCL 1.2: */ | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clEnqueueMigrateMemINTEL( | |
cl_command_queue command_queue, | |
const void* ptr, | |
size_t size, | |
cl_mem_migration_flags flags, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clEnqueueMigrateMemINTEL_fn)( | |
cl_command_queue command_queue, | |
const void* ptr, | |
size_t size, | |
cl_mem_migration_flags flags, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
extern CL_API_ENTRY cl_int CL_API_CALL | |
clEnqueueMemAdviseINTEL( | |
cl_command_queue command_queue, | |
const void* ptr, | |
size_t size, | |
cl_mem_advice_intel advice, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
typedef CL_API_ENTRY cl_int (CL_API_CALL * | |
clEnqueueMemAdviseINTEL_fn)( | |
cl_command_queue command_queue, | |
const void* ptr, | |
size_t size, | |
cl_mem_advice_intel advice, | |
cl_uint num_events_in_wait_list, | |
const cl_event* event_wait_list, | |
cl_event* event); | |
/*************************************************** | |
* cl_intel_create_buffer_with_properties extension * | |
****************************************************/ | |
extern CL_API_ENTRY cl_mem CL_API_CALL | |
clCreateBufferWithPropertiesINTEL( | |
cl_context context, | |
const cl_mem_properties_intel* properties, | |
cl_mem_flags flags, | |
size_t size, | |
void * host_ptr, | |
cl_int * errcode_ret) CL_EXT_SUFFIX__VERSION_1_0; | |
typedef CL_API_ENTRY cl_mem (CL_API_CALL * | |
clCreateBufferWithPropertiesINTEL_fn)( | |
cl_context context, | |
const cl_mem_properties_intel* properties, | |
cl_mem_flags flags, | |
size_t size, | |
void * host_ptr, | |
cl_int * errcode_ret) CL_EXT_SUFFIX__VERSION_1_0; | |
/****************************************** | |
* cl_intel_mem_channel_property extension * | |
*******************************************/ | |
} | |