Skip to content

[SYCL][UR] Update UR loader version #8979

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion sycl/plugins/unified_runtime/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ if (NOT DEFINED UNIFIED_RUNTIME_LIBRARY OR NOT DEFINED UNIFIED_RUNTIME_INCLUDE_D
include(FetchContent)

set(UNIFIED_RUNTIME_REPO "https://github.com/oneapi-src/unified-runtime.git")
set(UNIFIED_RUNTIME_TAG d6af758779db6eebdc419fd5e249302f566eb5de)
set(UNIFIED_RUNTIME_TAG 74843ea0800e6fb7ce0f82e0ef991fc258f4b9bd)

message(STATUS "Will fetch Unified Runtime from ${UNIFIED_RUNTIME_REPO}")
FetchContent_Declare(unified-runtime
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -662,25 +662,26 @@ ur_result_t urDeviceGetInfo(
ze_device_fp_flags_t ZeSingleFPCapabilities =
Device->ZeDeviceModuleProperties->fp32flags;
if (ZE_DEVICE_FP_FLAG_DENORM & ZeSingleFPCapabilities) {
SingleFPValue |= UR_FP_CAPABILITY_FLAG_DENORM;
SingleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_DENORM;
}
if (ZE_DEVICE_FP_FLAG_INF_NAN & ZeSingleFPCapabilities) {
SingleFPValue |= UR_FP_CAPABILITY_FLAG_INF_NAN;
SingleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_INF_NAN;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_NEAREST & ZeSingleFPCapabilities) {
SingleFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_NEAREST;
SingleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_NEAREST;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_ZERO & ZeSingleFPCapabilities) {
SingleFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_ZERO;
SingleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_ZERO;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_INF & ZeSingleFPCapabilities) {
SingleFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_INF;
SingleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_INF;
}
if (ZE_DEVICE_FP_FLAG_FMA & ZeSingleFPCapabilities) {
SingleFPValue |= UR_FP_CAPABILITY_FLAG_FMA;
SingleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_FMA;
}
if (ZE_DEVICE_FP_FLAG_ROUNDED_DIVIDE_SQRT & ZeSingleFPCapabilities) {
SingleFPValue |= UR_FP_CAPABILITY_FLAG_CORRECTLY_ROUNDED_DIVIDE_SQRT;
SingleFPValue |=
UR_DEVICE_FP_CAPABILITY_FLAG_CORRECTLY_ROUNDED_DIVIDE_SQRT;
}
return ReturnValue(uint64_t{SingleFPValue});
}
Expand All @@ -689,25 +690,25 @@ ur_result_t urDeviceGetInfo(
ze_device_fp_flags_t ZeHalfFPCapabilities =
Device->ZeDeviceModuleProperties->fp16flags;
if (ZE_DEVICE_FP_FLAG_DENORM & ZeHalfFPCapabilities) {
HalfFPValue |= UR_FP_CAPABILITY_FLAG_DENORM;
HalfFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_DENORM;
}
if (ZE_DEVICE_FP_FLAG_INF_NAN & ZeHalfFPCapabilities) {
HalfFPValue |= UR_FP_CAPABILITY_FLAG_INF_NAN;
HalfFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_INF_NAN;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_NEAREST & ZeHalfFPCapabilities) {
HalfFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_NEAREST;
HalfFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_NEAREST;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_ZERO & ZeHalfFPCapabilities) {
HalfFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_ZERO;
HalfFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_ZERO;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_INF & ZeHalfFPCapabilities) {
HalfFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_INF;
HalfFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_INF;
}
if (ZE_DEVICE_FP_FLAG_FMA & ZeHalfFPCapabilities) {
HalfFPValue |= UR_FP_CAPABILITY_FLAG_FMA;
HalfFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_FMA;
}
if (ZE_DEVICE_FP_FLAG_ROUNDED_DIVIDE_SQRT & ZeHalfFPCapabilities) {
HalfFPValue |= UR_FP_CAPABILITY_FLAG_CORRECTLY_ROUNDED_DIVIDE_SQRT;
HalfFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_CORRECTLY_ROUNDED_DIVIDE_SQRT;
}
return ReturnValue(uint64_t{HalfFPValue});
}
Expand All @@ -716,25 +717,26 @@ ur_result_t urDeviceGetInfo(
ze_device_fp_flags_t ZeDoubleFPCapabilities =
Device->ZeDeviceModuleProperties->fp64flags;
if (ZE_DEVICE_FP_FLAG_DENORM & ZeDoubleFPCapabilities) {
DoubleFPValue |= UR_FP_CAPABILITY_FLAG_DENORM;
DoubleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_DENORM;
}
if (ZE_DEVICE_FP_FLAG_INF_NAN & ZeDoubleFPCapabilities) {
DoubleFPValue |= UR_FP_CAPABILITY_FLAG_INF_NAN;
DoubleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_INF_NAN;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_NEAREST & ZeDoubleFPCapabilities) {
DoubleFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_NEAREST;
DoubleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_NEAREST;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_ZERO & ZeDoubleFPCapabilities) {
DoubleFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_ZERO;
DoubleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_ZERO;
}
if (ZE_DEVICE_FP_FLAG_ROUND_TO_INF & ZeDoubleFPCapabilities) {
DoubleFPValue |= UR_FP_CAPABILITY_FLAG_ROUND_TO_INF;
DoubleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_ROUND_TO_INF;
}
if (ZE_DEVICE_FP_FLAG_FMA & ZeDoubleFPCapabilities) {
DoubleFPValue |= UR_FP_CAPABILITY_FLAG_FMA;
DoubleFPValue |= UR_DEVICE_FP_CAPABILITY_FLAG_FMA;
}
if (ZE_DEVICE_FP_FLAG_ROUNDED_DIVIDE_SQRT & ZeDoubleFPCapabilities) {
DoubleFPValue |= UR_FP_CAPABILITY_FLAG_CORRECTLY_ROUNDED_DIVIDE_SQRT;
DoubleFPValue |=
UR_DEVICE_FP_CAPABILITY_FLAG_CORRECTLY_ROUNDED_DIVIDE_SQRT;
}
return ReturnValue(uint64_t{DoubleFPValue});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ UR_DLLEXPORT ur_result_t UR_APICALL urGetEnqueueProcAddrTable(
pDdiTable->pfnMemUnmap = nullptr;
pDdiTable->pfnUSMMemcpy = nullptr;
pDdiTable->pfnUSMPrefetch = nullptr;
pDdiTable->pfnUSMMemAdvise = nullptr;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was renamed, this variable is not in table anymore

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bmyates could you add the new name, instead of removing it?

https://github.com/oneapi-src/unified-runtime/blob/416b86a2c3de9e7104cf3ba5d11f064eff9c10fe/include/ur_ddi.h#L1042

    ur_pfnEnqueueUSMPrefetch_t pfnUSMPrefetch;
    ur_pfnEnqueueUSMAdvise_t pfnUSMAdvise;
    ur_pfnEnqueueUSMFill2D_t pfnUSMFill2D;

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added

pDdiTable->pfnUSMAdvise = nullptr;
pDdiTable->pfnUSMFill2D = nullptr;
pDdiTable->pfnUSMMemcpy2D = nullptr;
pDdiTable->pfnDeviceGlobalVariableWrite = nullptr;
Expand Down
4 changes: 0 additions & 4 deletions sycl/plugins/unified_runtime/ur/ur.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,6 @@ const int UR_EXT_DEVICE_INFO_FREE_MEMORY = UR_EXT_DEVICE_INFO_END - 13;
// const int ZER_EXT_DEVICE_INFO_DEVICE_ID = UR_EXT_DEVICE_INFO_END - 14;
// const int ZER_EXT_DEVICE_INFO_IMAGE_MAX_ARRAY_SIZE =
// UR_DEVICE_INFO_IMAGE_MAX_ARRAY_SIZE;
const int UR_DEVICE_INFO_ATOMIC_FENCE_ORDER_CAPABILITIES =
UR_EXT_DEVICE_INFO_END - 16;
const int UR_DEVICE_INFO_ATOMIC_FENCE_SCOPE_CAPABILITIES =
UR_EXT_DEVICE_INFO_END - 17;

const ur_device_info_t UR_EXT_DEVICE_INFO_OPENCL_C_VERSION =
(ur_device_info_t)0x103D;
Expand Down