Publishing R3
[platform/upstream/dldt.git] / inference-engine / thirdparty / clDNN / api / C / custom_gpu_primitive.h
1 /*
2 // Copyright (c) 2016 Intel Corporation
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 //      http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 */
16
17 ///////////////////////////////////////////////////////////////////////////////////////////////////
18 #ifndef CUSTOM_GPU_PRIMITIVE_H
19 #define CUSTOM_GPU_PRIMITIVE_H
20
21 #include "cldnn.h"
22 /// @addtogroup c_api C API
23 /// @{
24 /// @addtogroup c_topology Network Topology
25 /// @{
26 /// @addtogroup c_primitives Primitives
27 /// @{
28
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
32
33 /// @brief This primitive executes a custom kernel provided by the application
34 /// @details The application is required to provide all relevant details for executing the custom kernel
35 /// such as: sources, entry point, work sizes and parameter bindings.
36 CLDNN_BEGIN_PRIMITIVE_DESC(custom_gpu_primitive)
37 /// @brief Source code for the kernel
38 cldnn_primitive_id_arr kernels_code;
39 /// @brief The name of the entry point function in the kernel
40 cldnn_kernel_entry_point kernel_entry_point;
41 /// @brief Argument bindings for the entry point function
42 cldnn_kernel_arguments kernel_arguments;
43 /// @brief The number of arguments used by the kernel
44 int kernel_arguments_num;
45 /// @brief The kernel's build options
46 cldnn_kernel_build_options build_options;
47 /// @brief The output layout declared by the primitive
48 cldnn_layout output_layout;
49 /// @brief The global working sizes
50 cldnn_work_group_sizes gws;
51 /// @brief The number of global work sizes
52 int gws_num;
53 /// @brief The local working sizes
54 cldnn_work_group_sizes lws;
55 /// @brief The number of local work sizes
56 int lws_num;
57
58 CLDNN_END_PRIMITIVE_DESC(custom_gpu_primitive)
59
60 CLDNN_DECLARE_PRIMITIVE_TYPE_ID(custom_gpu_primitive);
61
62 #ifdef __cplusplus
63 }
64 #endif
65
66 /// @}
67 /// @}
68 /// @}
69 #endif /* CUSTOM_GPU_PRIMITIVE_H */
70