@@ -258,6 +258,7 @@ typedef enum ur_structure_type_t {
258258 UR_STRUCTURE_TYPE_KERNEL_EXEC_INFO_PROPERTIES = 31, ///< ::ur_kernel_exec_info_properties_t
259259 UR_STRUCTURE_TYPE_KERNEL_ARG_VALUE_PROPERTIES = 32, ///< ::ur_kernel_arg_value_properties_t
260260 UR_STRUCTURE_TYPE_KERNEL_ARG_LOCAL_PROPERTIES = 33, ///< ::ur_kernel_arg_local_properties_t
261+ UR_STRUCTURE_TYPE_USM_ALLOC_LOCATION_DESC = 35, ///< ::ur_usm_alloc_location_desc_t
261262 UR_STRUCTURE_TYPE_EXP_COMMAND_BUFFER_DESC = 0x1000, ///< ::ur_exp_command_buffer_desc_t
262263 UR_STRUCTURE_TYPE_EXP_SAMPLER_MIP_PROPERTIES = 0x2000, ///< ::ur_exp_sampler_mip_properties_t
263264 UR_STRUCTURE_TYPE_EXP_INTEROP_MEM_DESC = 0x2001, ///< ::ur_exp_interop_mem_desc_t
@@ -3287,6 +3288,25 @@ typedef struct ur_usm_device_desc_t {
32873288
32883289} ur_usm_device_desc_t;
32893290
3291+ ///////////////////////////////////////////////////////////////////////////////
3292+ /// @brief USM allocation location desc
3293+ ///
3294+ /// @details
3295+ /// - Specify these properties in ::urUSMHostAlloc, ::urUSMDeviceAlloc and
3296+ /// ::urUSMSharedAlloc via ::ur_usm_desc_t as part of a `pNext` chain.
3297+ ///
3298+ /// @remarks
3299+ /// _Analogues_
3300+ /// - cl_intel_mem_alloc_buffer_location
3301+ typedef struct ur_usm_alloc_location_desc_t {
3302+ ur_structure_type_t stype; ///< [in] type of this structure, must be
3303+ ///< ::UR_STRUCTURE_TYPE_USM_ALLOC_LOCATION_DESC
3304+ const void *pNext; ///< [in][optional] pointer to extension-specific structure
3305+ uint32_t location; ///< [in] Identifies the ID of global memory partition to which the memory
3306+ ///< should be allocated.
3307+
3308+ } ur_usm_alloc_location_desc_t;
3309+
32903310///////////////////////////////////////////////////////////////////////////////
32913311/// @brief USM pool descriptor type
32923312typedef struct ur_usm_pool_desc_t {
@@ -3324,6 +3344,7 @@ typedef struct ur_usm_pool_limits_desc_t {
33243344/// - Any flags/hints passed through pUSMDesc only affect the single
33253345/// allocation.
33263346/// - See also ::ur_usm_host_desc_t.
3347+ /// - See also ::ur_usm_alloc_location_desc_t.
33273348///
33283349/// @returns
33293350/// - ::UR_RESULT_SUCCESS
@@ -3369,6 +3390,7 @@ urUSMHostAlloc(
33693390/// - Any flags/hints passed through pUSMDesc only affect the single
33703391/// allocation.
33713392/// - See also ::ur_usm_device_desc_t.
3393+ /// - See also ::ur_usm_alloc_location_desc_t.
33723394///
33733395/// @returns
33743396/// - ::UR_RESULT_SUCCESS
@@ -3417,6 +3439,7 @@ urUSMDeviceAlloc(
34173439/// allocation.
34183440/// - See also ::ur_usm_host_desc_t.
34193441/// - See also ::ur_usm_device_desc_t.
3442+ /// - See also ::ur_usm_alloc_location_desc_t.
34203443///
34213444/// @returns
34223445/// - ::UR_RESULT_SUCCESS
0 commit comments