@@ -205,6 +205,9 @@ typedef enum ur_function_t {
205
205
UR_FUNCTION_ADAPTER_RETAIN = 179, ///< Enumerator for ::urAdapterRetain
206
206
UR_FUNCTION_ADAPTER_GET_LAST_ERROR = 180, ///< Enumerator for ::urAdapterGetLastError
207
207
UR_FUNCTION_ADAPTER_GET_INFO = 181, ///< Enumerator for ::urAdapterGetInfo
208
+ UR_FUNCTION_PROGRAM_BUILD_EXP = 197, ///< Enumerator for ::urProgramBuildExp
209
+ UR_FUNCTION_PROGRAM_COMPILE_EXP = 198, ///< Enumerator for ::urProgramCompileExp
210
+ UR_FUNCTION_PROGRAM_LINK_EXP = 199, ///< Enumerator for ::urProgramLinkExp
208
211
/// @cond
209
212
UR_FUNCTION_FORCE_UINT32 = 0x7fffffff
210
213
/// @endcond
@@ -8030,6 +8033,131 @@ urCommandBufferEnqueueExp(
8030
8033
///< command-buffer execution instance.
8031
8034
);
8032
8035
8036
+ #if !defined(__GNUC__)
8037
+ #pragma endregion
8038
+ #endif
8039
+ // Intel 'oneAPI' Unified Runtime Experimental APIs for multi-device compile
8040
+ #if !defined(__GNUC__)
8041
+ #pragma region multi device compile(experimental)
8042
+ #endif
8043
+ ///////////////////////////////////////////////////////////////////////////////
8044
+ #ifndef UR_MULTI_DEVICE_COMPILE_EXTENSION_STRING_EXP
8045
+ /// @brief The extension string which defines support for test
8046
+ /// which is returned when querying device extensions.
8047
+ #define UR_MULTI_DEVICE_COMPILE_EXTENSION_STRING_EXP "ur_exp_multi_device_compile"
8048
+ #endif // UR_MULTI_DEVICE_COMPILE_EXTENSION_STRING_EXP
8049
+
8050
+ ///////////////////////////////////////////////////////////////////////////////
8051
+ /// @brief Produces an executable program from one program, negates need for the
8052
+ /// linking step.
8053
+ ///
8054
+ /// @details
8055
+ /// - The application may call this function from simultaneous threads.
8056
+ /// - Following a successful call to this entry point, the program passed
8057
+ /// will contain a binary of the ::UR_PROGRAM_BINARY_TYPE_EXECUTABLE type
8058
+ /// for each device in `phDevices`.
8059
+ ///
8060
+ /// @remarks
8061
+ /// _Analogues_
8062
+ /// - **clBuildProgram**
8063
+ ///
8064
+ /// @returns
8065
+ /// - ::UR_RESULT_SUCCESS
8066
+ /// - ::UR_RESULT_ERROR_UNINITIALIZED
8067
+ /// - ::UR_RESULT_ERROR_DEVICE_LOST
8068
+ /// - ::UR_RESULT_ERROR_ADAPTER_SPECIFIC
8069
+ /// - ::UR_RESULT_ERROR_INVALID_NULL_HANDLE
8070
+ /// + `NULL == hProgram`
8071
+ /// - ::UR_RESULT_ERROR_INVALID_NULL_POINTER
8072
+ /// + `NULL == phDevices`
8073
+ /// - ::UR_RESULT_ERROR_INVALID_PROGRAM
8074
+ /// + If `hProgram` isn't a valid program object.
8075
+ /// - ::UR_RESULT_ERROR_PROGRAM_BUILD_FAILURE
8076
+ /// + If an error occurred when building `hProgram`.
8077
+ UR_APIEXPORT ur_result_t UR_APICALL
8078
+ urProgramBuildExp(
8079
+ ur_program_handle_t hProgram, ///< [in] Handle of the program to build.
8080
+ uint32_t numDevices, ///< [in] number of devices
8081
+ ur_device_handle_t *phDevices, ///< [in][range(0, numDevices)] pointer to array of device handles
8082
+ const char *pOptions ///< [in][optional] pointer to build options null-terminated string.
8083
+ );
8084
+
8085
+ ///////////////////////////////////////////////////////////////////////////////
8086
+ /// @brief Produces an executable program from one or more programs.
8087
+ ///
8088
+ /// @details
8089
+ /// - The application may call this function from simultaneous threads.
8090
+ /// - Following a successful call to this entry point `hProgram` will
8091
+ /// contain a binary of the ::UR_PROGRAM_BINARY_TYPE_COMPILED_OBJECT type
8092
+ /// for each device in `phDevices`.
8093
+ ///
8094
+ /// @remarks
8095
+ /// _Analogues_
8096
+ /// - **clCompileProgram**
8097
+ ///
8098
+ /// @returns
8099
+ /// - ::UR_RESULT_SUCCESS
8100
+ /// - ::UR_RESULT_ERROR_UNINITIALIZED
8101
+ /// - ::UR_RESULT_ERROR_DEVICE_LOST
8102
+ /// - ::UR_RESULT_ERROR_ADAPTER_SPECIFIC
8103
+ /// - ::UR_RESULT_ERROR_INVALID_NULL_HANDLE
8104
+ /// + `NULL == hProgram`
8105
+ /// - ::UR_RESULT_ERROR_INVALID_NULL_POINTER
8106
+ /// + `NULL == phDevices`
8107
+ /// - ::UR_RESULT_ERROR_INVALID_PROGRAM
8108
+ /// + If `hProgram` isn't a valid program object.
8109
+ /// - ::UR_RESULT_ERROR_PROGRAM_BUILD_FAILURE
8110
+ /// + If an error occurred while compiling `hProgram`.
8111
+ UR_APIEXPORT ur_result_t UR_APICALL
8112
+ urProgramCompileExp(
8113
+ ur_program_handle_t hProgram, ///< [in][out] handle of the program to compile.
8114
+ uint32_t numDevices, ///< [in] number of devices
8115
+ ur_device_handle_t *phDevices, ///< [in][range(0, numDevices)] pointer to array of device handles
8116
+ const char *pOptions ///< [in][optional] pointer to build options null-terminated string.
8117
+ );
8118
+
8119
+ ///////////////////////////////////////////////////////////////////////////////
8120
+ /// @brief Produces an executable program from one or more programs.
8121
+ ///
8122
+ /// @details
8123
+ /// - The application may call this function from simultaneous threads.
8124
+ /// - Following a successful call to this entry point the program returned
8125
+ /// in `phProgram` will contain a binary of the
8126
+ /// ::UR_PROGRAM_BINARY_TYPE_EXECUTABLE type for each device in
8127
+ /// `phDevices`.
8128
+ ///
8129
+ /// @remarks
8130
+ /// _Analogues_
8131
+ /// - **clLinkProgram**
8132
+ ///
8133
+ /// @returns
8134
+ /// - ::UR_RESULT_SUCCESS
8135
+ /// - ::UR_RESULT_ERROR_UNINITIALIZED
8136
+ /// - ::UR_RESULT_ERROR_DEVICE_LOST
8137
+ /// - ::UR_RESULT_ERROR_ADAPTER_SPECIFIC
8138
+ /// - ::UR_RESULT_ERROR_INVALID_NULL_HANDLE
8139
+ /// + `NULL == hContext`
8140
+ /// - ::UR_RESULT_ERROR_INVALID_NULL_POINTER
8141
+ /// + `NULL == phDevices`
8142
+ /// + `NULL == phPrograms`
8143
+ /// + `NULL == phProgram`
8144
+ /// - ::UR_RESULT_ERROR_INVALID_PROGRAM
8145
+ /// + If one of the programs in `phPrograms` isn't a valid program object.
8146
+ /// - ::UR_RESULT_ERROR_INVALID_SIZE
8147
+ /// + `count == 0`
8148
+ /// - ::UR_RESULT_ERROR_PROGRAM_LINK_FAILURE
8149
+ /// + If an error occurred while linking `phPrograms`.
8150
+ UR_APIEXPORT ur_result_t UR_APICALL
8151
+ urProgramLinkExp(
8152
+ ur_context_handle_t hContext, ///< [in] handle of the context instance.
8153
+ uint32_t numDevices, ///< [in] number of devices
8154
+ ur_device_handle_t *phDevices, ///< [in][range(0, numDevices)] pointer to array of device handles
8155
+ uint32_t count, ///< [in] number of program handles in `phPrograms`.
8156
+ const ur_program_handle_t *phPrograms, ///< [in][range(0, count)] pointer to array of program handles.
8157
+ const char *pOptions, ///< [in][optional] pointer to linker options null-terminated string.
8158
+ ur_program_handle_t *phProgram ///< [out] pointer to handle of program object created.
8159
+ );
8160
+
8033
8161
#if !defined(__GNUC__)
8034
8162
#pragma endregion
8035
8163
#endif
@@ -8531,6 +8659,17 @@ typedef struct ur_program_build_params_t {
8531
8659
const char **ppOptions;
8532
8660
} ur_program_build_params_t;
8533
8661
8662
+ ///////////////////////////////////////////////////////////////////////////////
8663
+ /// @brief Function parameters for urProgramBuildExp
8664
+ /// @details Each entry is a pointer to the parameter passed to the function;
8665
+ /// allowing the callback the ability to modify the parameter's value
8666
+ typedef struct ur_program_build_exp_params_t {
8667
+ ur_program_handle_t *phProgram;
8668
+ uint32_t *pnumDevices;
8669
+ ur_device_handle_t **pphDevices;
8670
+ const char **ppOptions;
8671
+ } ur_program_build_exp_params_t;
8672
+
8534
8673
///////////////////////////////////////////////////////////////////////////////
8535
8674
/// @brief Function parameters for urProgramCompile
8536
8675
/// @details Each entry is a pointer to the parameter passed to the function;
@@ -8541,6 +8680,17 @@ typedef struct ur_program_compile_params_t {
8541
8680
const char **ppOptions;
8542
8681
} ur_program_compile_params_t;
8543
8682
8683
+ ///////////////////////////////////////////////////////////////////////////////
8684
+ /// @brief Function parameters for urProgramCompileExp
8685
+ /// @details Each entry is a pointer to the parameter passed to the function;
8686
+ /// allowing the callback the ability to modify the parameter's value
8687
+ typedef struct ur_program_compile_exp_params_t {
8688
+ ur_program_handle_t *phProgram;
8689
+ uint32_t *pnumDevices;
8690
+ ur_device_handle_t **pphDevices;
8691
+ const char **ppOptions;
8692
+ } ur_program_compile_exp_params_t;
8693
+
8544
8694
///////////////////////////////////////////////////////////////////////////////
8545
8695
/// @brief Function parameters for urProgramLink
8546
8696
/// @details Each entry is a pointer to the parameter passed to the function;
@@ -8553,6 +8703,20 @@ typedef struct ur_program_link_params_t {
8553
8703
ur_program_handle_t **pphProgram;
8554
8704
} ur_program_link_params_t;
8555
8705
8706
+ ///////////////////////////////////////////////////////////////////////////////
8707
+ /// @brief Function parameters for urProgramLinkExp
8708
+ /// @details Each entry is a pointer to the parameter passed to the function;
8709
+ /// allowing the callback the ability to modify the parameter's value
8710
+ typedef struct ur_program_link_exp_params_t {
8711
+ ur_context_handle_t *phContext;
8712
+ uint32_t *pnumDevices;
8713
+ ur_device_handle_t **pphDevices;
8714
+ uint32_t *pcount;
8715
+ const ur_program_handle_t **pphPrograms;
8716
+ const char **ppOptions;
8717
+ ur_program_handle_t **pphProgram;
8718
+ } ur_program_link_exp_params_t;
8719
+
8556
8720
///////////////////////////////////////////////////////////////////////////////
8557
8721
/// @brief Function parameters for urProgramRetain
8558
8722
/// @details Each entry is a pointer to the parameter passed to the function;
0 commit comments