Skip to content

Testing for UR adapter branch bump first patch #11708

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
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
12 changes: 6 additions & 6 deletions sycl/plugins/unified_runtime/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,13 @@ if(SYCL_PI_UR_USE_FETCH_CONTENT)
include(FetchContent)

set(UNIFIED_RUNTIME_REPO "https://github.com/oneapi-src/unified-runtime.git")
# commit ec7982bac6cb3a6b9ed610cd6b7cb41fcbc780dc
# Merge: 62e6d2f9 5fb82924
# commit: 7c8617b3710736db642585fe310a64e19e059d2e
# Merge: 20d4f49 9a13af
# Author: Kenneth Benzie (Benie) <[email protected]>
# Date: Wed Nov 8 13:32:46 2023 +0000
# Merge pull request #1022 from 0x12CC/l0_usm_error_checking_2
# [UR][L0] Propagate OOM errors from `USMAllocationMakeResident`
set(UNIFIED_RUNTIME_TAG ec7982bac6cb3a6b9ed610cd6b7cb41fcbc780dc)
# Date: Thu Oct 26 10:20:03 2023 +0100
# Merge pull request #965 from Bensuo/ewan/L0_internal_event_fix
# [Command-buffer][L0] Reset sync-point events
set(UNIFIED_RUNTIME_TAG fb00d47cdc403a67b7fa182f55a33de8e7500ed7)

if(SYCL_PI_UR_OVERRIDE_FETCH_CONTENT_REPO)
set(UNIFIED_RUNTIME_REPO "${SYCL_PI_UR_OVERRIDE_FETCH_CONTENT_REPO}")
Expand Down
14 changes: 12 additions & 2 deletions sycl/plugins/unified_runtime/pi2ur.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2336,8 +2336,18 @@ inline pi_result piKernelGetInfo(pi_kernel Kernel, pi_kernel_info ParamName,
break;
}
case PI_KERNEL_INFO_NUM_ARGS: {
UrParamName = UR_KERNEL_INFO_NUM_ARGS;
break;
size_t NumArgs = 0;
HANDLE_ERRORS(urKernelGetInfo(UrKernel, UR_KERNEL_INFO_NUM_ARGS,
sizeof(NumArgs), &NumArgs, nullptr));
if (ParamValueSizeRet) {
*ParamValueSizeRet = sizeof(uint32_t);
}
if (ParamValue) {
if (ParamValueSize != sizeof(uint32_t))
return PI_ERROR_INVALID_BUFFER_SIZE;
*static_cast<uint32_t *>(ParamValue) = static_cast<uint32_t>(NumArgs);
}
return PI_SUCCESS;
}
case PI_KERNEL_INFO_REFERENCE_COUNT: {
UrParamName = UR_KERNEL_INFO_REFERENCE_COUNT;
Expand Down
4 changes: 2 additions & 2 deletions sycl/source/backend.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -174,10 +174,10 @@ make_kernel_bundle(pi_native_handle NativeHandle, const context &TargetContext,
Plugin->call<PiApiKind::piProgramRetain>(PiProgram);

std::vector<pi::PiDevice> ProgramDevices;
size_t NumDevices = 0;
uint32_t NumDevices = 0;

Plugin->call<PiApiKind::piProgramGetInfo>(
PiProgram, PI_PROGRAM_INFO_NUM_DEVICES, sizeof(size_t), &NumDevices,
PiProgram, PI_PROGRAM_INFO_NUM_DEVICES, sizeof(NumDevices), &NumDevices,
nullptr);
ProgramDevices.resize(NumDevices);
Plugin->call<PiApiKind::piProgramGetInfo>(PiProgram, PI_PROGRAM_INFO_DEVICES,
Expand Down
2 changes: 1 addition & 1 deletion sycl/source/detail/context_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ context_impl::context_impl(sycl::detail::pi::PiContext PiContext,
MSupportBufferLocationByDevices(NotChecked) {

std::vector<sycl::detail::pi::PiDevice> DeviceIds;
size_t DevicesNum = 0;
uint32_t DevicesNum = 0;
// TODO catch an exception and put it to list of asynchronous exceptions
Plugin->call<PiApiKind::piContextGetInfo>(
MContext, PI_CONTEXT_INFO_NUM_DEVICES, sizeof(DevicesNum), &DevicesNum,
Expand Down