Skip to content

Commit c187246

Browse files
authored
Update Level Zero Loader and Headers to support v1.13.1 of L0 Spec (#325)
* Update Level Zero Loader and Headers to support v1.13.1 of L0 Spec * Update Product GUID * Add new ext ZE_STRUCTURE_TYPE_DEVICE_CACHELINE_SIZE_EXT to extension validation Signed-off-by: Neil R. Spruit <neil.r.spruit@intel.com>
1 parent 145eddf commit c187246

41 files changed

Lines changed: 8046 additions & 642 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Level zero loader changelog
22

3+
## v1.22.0
4+
* Update to support v1.13.1 of the Level Zero Spec
5+
* Add testing stdout from zeInitDrivers in CI
6+
* Only Enable Teardown thread on windows and remove debug on success
37
## v1.21.9
48
* Fix init checks when sorting legacy drivers
59
* Fix MSVC Link optimization flags

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ if(MSVC AND (MSVC_VERSION LESS 1900))
1313
endif()
1414

1515
# This project follows semantic versioning (https://semver.org/)
16-
project(level-zero VERSION 1.21.9)
16+
project(level-zero VERSION 1.22.0)
1717

1818
include(GNUInstallDirs)
1919

PRODUCT_GUID.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
1.21.9
2-
01037281-c9ef-43cf-bc65-f72fb3438788
1+
1.22.0
2+
144d1a88-75bd-4f4a-8871-3660a84f7380

include/layers/zel_tracing_register_cb.h

Lines changed: 388 additions & 0 deletions
Large diffs are not rendered by default.

include/ze.py

Lines changed: 806 additions & 9 deletions
Large diffs are not rendered by default.

include/ze_api.h

Lines changed: 1493 additions & 315 deletions
Large diffs are not rendered by default.

include/ze_ddi.h

Lines changed: 163 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* SPDX-License-Identifier: MIT
66
*
77
* @file ze_ddi.h
8-
* @version v1.12-r1.12.15
8+
* @version v1.13-r1.13.1
99
*
1010
*/
1111
#ifndef _ZE_DDI_H
@@ -19,6 +19,88 @@
1919
extern "C" {
2020
#endif
2121

22+
///////////////////////////////////////////////////////////////////////////////
23+
/// @brief Function-pointer for zeRTASBuilderCreateExt
24+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASBuilderCreateExt_t)(
25+
ze_driver_handle_t,
26+
const ze_rtas_builder_ext_desc_t*,
27+
ze_rtas_builder_ext_handle_t*
28+
);
29+
30+
///////////////////////////////////////////////////////////////////////////////
31+
/// @brief Function-pointer for zeRTASBuilderGetBuildPropertiesExt
32+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASBuilderGetBuildPropertiesExt_t)(
33+
ze_rtas_builder_ext_handle_t,
34+
const ze_rtas_builder_build_op_ext_desc_t*,
35+
ze_rtas_builder_ext_properties_t*
36+
);
37+
38+
///////////////////////////////////////////////////////////////////////////////
39+
/// @brief Function-pointer for zeRTASBuilderBuildExt
40+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASBuilderBuildExt_t)(
41+
ze_rtas_builder_ext_handle_t,
42+
const ze_rtas_builder_build_op_ext_desc_t*,
43+
void*,
44+
size_t,
45+
void*,
46+
size_t,
47+
ze_rtas_parallel_operation_ext_handle_t,
48+
void*,
49+
ze_rtas_aabb_ext_t*,
50+
size_t*
51+
);
52+
53+
///////////////////////////////////////////////////////////////////////////////
54+
/// @brief Function-pointer for zeRTASBuilderCommandListAppendCopyExt
55+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASBuilderCommandListAppendCopyExt_t)(
56+
ze_command_list_handle_t,
57+
void*,
58+
const void*,
59+
size_t,
60+
ze_event_handle_t,
61+
uint32_t,
62+
ze_event_handle_t*
63+
);
64+
65+
///////////////////////////////////////////////////////////////////////////////
66+
/// @brief Function-pointer for zeRTASBuilderDestroyExt
67+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASBuilderDestroyExt_t)(
68+
ze_rtas_builder_ext_handle_t
69+
);
70+
71+
///////////////////////////////////////////////////////////////////////////////
72+
/// @brief Table of RTASBuilder functions pointers
73+
typedef struct _ze_rtas_builder_dditable_t
74+
{
75+
ze_pfnRTASBuilderCreateExt_t pfnCreateExt;
76+
ze_pfnRTASBuilderGetBuildPropertiesExt_t pfnGetBuildPropertiesExt;
77+
ze_pfnRTASBuilderBuildExt_t pfnBuildExt;
78+
ze_pfnRTASBuilderCommandListAppendCopyExt_t pfnCommandListAppendCopyExt;
79+
ze_pfnRTASBuilderDestroyExt_t pfnDestroyExt;
80+
} ze_rtas_builder_dditable_t;
81+
82+
///////////////////////////////////////////////////////////////////////////////
83+
/// @brief Exported function for filling application's RTASBuilder table
84+
/// with current process' addresses
85+
///
86+
/// @returns
87+
/// - ::ZE_RESULT_SUCCESS
88+
/// - ::ZE_RESULT_ERROR_UNINITIALIZED
89+
/// - ::ZE_RESULT_ERROR_INVALID_NULL_POINTER
90+
/// - ::ZE_RESULT_ERROR_UNSUPPORTED_VERSION
91+
ZE_DLLEXPORT ze_result_t ZE_APICALL
92+
zeGetRTASBuilderProcAddrTable(
93+
ze_api_version_t version, ///< [in] API version requested
94+
ze_rtas_builder_dditable_t* pDdiTable ///< [in,out] pointer to table of DDI function pointers
95+
);
96+
97+
///////////////////////////////////////////////////////////////////////////////
98+
/// @brief Function-pointer for zeGetRTASBuilderProcAddrTable
99+
typedef ze_result_t (ZE_APICALL *ze_pfnGetRTASBuilderProcAddrTable_t)(
100+
ze_api_version_t,
101+
ze_rtas_builder_dditable_t*
102+
);
103+
22104
///////////////////////////////////////////////////////////////////////////////
23105
/// @brief Function-pointer for zeRTASBuilderCreateExp
24106
typedef ze_result_t (ZE_APICALL *ze_pfnRTASBuilderCreateExp_t)(
@@ -88,6 +170,64 @@ typedef ze_result_t (ZE_APICALL *ze_pfnGetRTASBuilderExpProcAddrTable_t)(
88170
ze_rtas_builder_exp_dditable_t*
89171
);
90172

173+
///////////////////////////////////////////////////////////////////////////////
174+
/// @brief Function-pointer for zeRTASParallelOperationCreateExt
175+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASParallelOperationCreateExt_t)(
176+
ze_driver_handle_t,
177+
ze_rtas_parallel_operation_ext_handle_t*
178+
);
179+
180+
///////////////////////////////////////////////////////////////////////////////
181+
/// @brief Function-pointer for zeRTASParallelOperationGetPropertiesExt
182+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASParallelOperationGetPropertiesExt_t)(
183+
ze_rtas_parallel_operation_ext_handle_t,
184+
ze_rtas_parallel_operation_ext_properties_t*
185+
);
186+
187+
///////////////////////////////////////////////////////////////////////////////
188+
/// @brief Function-pointer for zeRTASParallelOperationJoinExt
189+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASParallelOperationJoinExt_t)(
190+
ze_rtas_parallel_operation_ext_handle_t
191+
);
192+
193+
///////////////////////////////////////////////////////////////////////////////
194+
/// @brief Function-pointer for zeRTASParallelOperationDestroyExt
195+
typedef ze_result_t (ZE_APICALL *ze_pfnRTASParallelOperationDestroyExt_t)(
196+
ze_rtas_parallel_operation_ext_handle_t
197+
);
198+
199+
///////////////////////////////////////////////////////////////////////////////
200+
/// @brief Table of RTASParallelOperation functions pointers
201+
typedef struct _ze_rtas_parallel_operation_dditable_t
202+
{
203+
ze_pfnRTASParallelOperationCreateExt_t pfnCreateExt;
204+
ze_pfnRTASParallelOperationGetPropertiesExt_t pfnGetPropertiesExt;
205+
ze_pfnRTASParallelOperationJoinExt_t pfnJoinExt;
206+
ze_pfnRTASParallelOperationDestroyExt_t pfnDestroyExt;
207+
} ze_rtas_parallel_operation_dditable_t;
208+
209+
///////////////////////////////////////////////////////////////////////////////
210+
/// @brief Exported function for filling application's RTASParallelOperation table
211+
/// with current process' addresses
212+
///
213+
/// @returns
214+
/// - ::ZE_RESULT_SUCCESS
215+
/// - ::ZE_RESULT_ERROR_UNINITIALIZED
216+
/// - ::ZE_RESULT_ERROR_INVALID_NULL_POINTER
217+
/// - ::ZE_RESULT_ERROR_UNSUPPORTED_VERSION
218+
ZE_DLLEXPORT ze_result_t ZE_APICALL
219+
zeGetRTASParallelOperationProcAddrTable(
220+
ze_api_version_t version, ///< [in] API version requested
221+
ze_rtas_parallel_operation_dditable_t* pDdiTable ///< [in,out] pointer to table of DDI function pointers
222+
);
223+
224+
///////////////////////////////////////////////////////////////////////////////
225+
/// @brief Function-pointer for zeGetRTASParallelOperationProcAddrTable
226+
typedef ze_result_t (ZE_APICALL *ze_pfnGetRTASParallelOperationProcAddrTable_t)(
227+
ze_api_version_t,
228+
ze_rtas_parallel_operation_dditable_t*
229+
);
230+
91231
///////////////////////////////////////////////////////////////////////////////
92232
/// @brief Function-pointer for zeRTASParallelOperationCreateExp
93233
typedef ze_result_t (ZE_APICALL *ze_pfnRTASParallelOperationCreateExp_t)(
@@ -241,6 +381,14 @@ typedef ze_result_t (ZE_APICALL *ze_pfnDriverGetLastErrorDescription_t)(
241381
const char**
242382
);
243383

384+
///////////////////////////////////////////////////////////////////////////////
385+
/// @brief Function-pointer for zeDriverRTASFormatCompatibilityCheckExt
386+
typedef ze_result_t (ZE_APICALL *ze_pfnDriverRTASFormatCompatibilityCheckExt_t)(
387+
ze_driver_handle_t,
388+
ze_rtas_format_ext_t,
389+
ze_rtas_format_ext_t
390+
);
391+
244392
///////////////////////////////////////////////////////////////////////////////
245393
/// @brief Table of Driver functions pointers
246394
typedef struct _ze_driver_dditable_t
@@ -252,6 +400,7 @@ typedef struct _ze_driver_dditable_t
252400
ze_pfnDriverGetExtensionProperties_t pfnGetExtensionProperties;
253401
ze_pfnDriverGetExtensionFunctionAddress_t pfnGetExtensionFunctionAddress;
254402
ze_pfnDriverGetLastErrorDescription_t pfnGetLastErrorDescription;
403+
ze_pfnDriverRTASFormatCompatibilityCheckExt_t pfnRTASFormatCompatibilityCheckExt;
255404
} ze_driver_dditable_t;
256405

257406
///////////////////////////////////////////////////////////////////////////////
@@ -470,6 +619,14 @@ typedef ze_result_t (ZE_APICALL *ze_pfnDeviceReleaseExternalSemaphoreExt_t)(
470619
ze_external_semaphore_ext_handle_t
471620
);
472621

622+
///////////////////////////////////////////////////////////////////////////////
623+
/// @brief Function-pointer for zeDeviceGetVectorWidthPropertiesExt
624+
typedef ze_result_t (ZE_APICALL *ze_pfnDeviceGetVectorWidthPropertiesExt_t)(
625+
ze_device_handle_t,
626+
uint32_t*,
627+
ze_device_vector_width_properties_ext_t*
628+
);
629+
473630
///////////////////////////////////////////////////////////////////////////////
474631
/// @brief Table of Device functions pointers
475632
typedef struct _ze_device_dditable_t
@@ -495,6 +652,7 @@ typedef struct _ze_device_dditable_t
495652
ze_pfnDeviceGetRootDevice_t pfnGetRootDevice;
496653
ze_pfnDeviceImportExternalSemaphoreExt_t pfnImportExternalSemaphoreExt;
497654
ze_pfnDeviceReleaseExternalSemaphoreExt_t pfnReleaseExternalSemaphoreExt;
655+
ze_pfnDeviceGetVectorWidthPropertiesExt_t pfnGetVectorWidthPropertiesExt;
498656
} ze_device_dditable_t;
499657

500658
///////////////////////////////////////////////////////////////////////////////
@@ -2588,7 +2746,9 @@ typedef ze_result_t (ZE_APICALL *ze_pfnGetFabricEdgeExpProcAddrTable_t)(
25882746
/// @brief Container for all DDI tables
25892747
typedef struct _ze_dditable_t
25902748
{
2749+
ze_rtas_builder_dditable_t RTASBuilder;
25912750
ze_rtas_builder_exp_dditable_t RTASBuilderExp;
2751+
ze_rtas_parallel_operation_dditable_t RTASParallelOperation;
25922752
ze_rtas_parallel_operation_exp_dditable_t RTASParallelOperationExp;
25932753
ze_global_dditable_t Global;
25942754
ze_driver_dditable_t Driver;
@@ -2622,7 +2782,9 @@ typedef struct _ze_dditable_driver_t
26222782
{
26232783
ze_api_version_t version;
26242784
uint8_t isValidFlag;
2785+
ze_rtas_builder_dditable_t * RTASBuilder;
26252786
ze_rtas_builder_exp_dditable_t * RTASBuilderExp;
2787+
ze_rtas_parallel_operation_dditable_t * RTASParallelOperation;
26262788
ze_rtas_parallel_operation_exp_dditable_t * RTASParallelOperationExp;
26272789
ze_global_dditable_t * Global;
26282790
ze_driver_dditable_t * Driver;

include/ze_ddi_common.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* SPDX-License-Identifier: MIT
66
*
77
* @file ze_ddi_common.h
8-
* @version v1.12-r1.12.15
8+
* @version v1.13-r1.13.1
99
*
1010
*/
1111
#ifndef _ZE_DDI_COMMON_H

include/zes.py

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
SPDX-License-Identifier: MIT
55
66
@file zes.py
7-
@version v1.12-r1.12.15
7+
@version v1.13-r1.13.1
88
99
"""
1010
import platform
@@ -169,6 +169,7 @@ class zes_structure_type_v(IntEnum):
169169
VF_UTIL_MEM_EXP2 = 0x00020009 ## ::zes_vf_util_mem_exp2_t
170170
VF_UTIL_ENGINE_EXP2 = 0x00020010 ## ::zes_vf_util_engine_exp2_t
171171
VF_EXP2_CAPABILITIES = 0x00020011 ## ::zes_vf_exp2_capabilities_t
172+
DEVICE_ECC_DEFAULT_PROPERTIES_EXT = 0x00020012 ## ::zes_device_ecc_default_properties_ext_t
172173

173174
class zes_structure_type_t(c_int):
174175
def __str__(self):
@@ -2147,6 +2148,32 @@ class zes_temp_config_t(Structure):
21472148
## driver.
21482149
]
21492150

2151+
###############################################################################
2152+
## @brief Device ECC default properties Extension Name
2153+
ZES_DEVICE_ECC_DEFAULT_PROPERTIES_EXT_NAME = "ZES_extension_device_ecc_default_properties"
2154+
2155+
###############################################################################
2156+
## @brief Device ECC default properties Extension Version(s)
2157+
class zes_device_ecc_default_properties_ext_version_v(IntEnum):
2158+
_1_0 = ZE_MAKE_VERSION( 1, 0 ) ## version 1.0
2159+
CURRENT = ZE_MAKE_VERSION( 1, 0 ) ## latest known version
2160+
2161+
class zes_device_ecc_default_properties_ext_version_t(c_int):
2162+
def __str__(self):
2163+
return str(zes_device_ecc_default_properties_ext_version_v(self.value))
2164+
2165+
2166+
###############################################################################
2167+
## @brief This structure may be passed to ::zesDeviceGetEccState as pNext member
2168+
## of ::zes_device_ecc_properties_t.
2169+
class zes_device_ecc_default_properties_ext_t(Structure):
2170+
_fields_ = [
2171+
("stype", zes_structure_type_t), ## [in] type of this structure
2172+
("pNext", c_void_p), ## [in,out][optional] must be null or a pointer to an extension-specific
2173+
## structure (i.e. contains stype and pNext).
2174+
("defaultState", zes_device_ecc_state_t) ## [out] Default ECC state
2175+
]
2176+
21502177
###############################################################################
21512178
## @brief Power Limits Extension Name
21522179
ZES_POWER_LIMITS_EXT_NAME = "ZES_extension_power_limits"

0 commit comments

Comments
 (0)