Skip to content

[UR][L0] Disable Immediate Command List DG2 Windows #2730

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

Merged
merged 1 commit into from
Mar 6, 2025
Merged
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 CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

cmake_minimum_required(VERSION 3.20.0 FATAL_ERROR)
project(unified-runtime VERSION 0.11.8)
project(unified-runtime VERSION 0.11.9)

# Check if unified runtime is built as a standalone project.
if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR OR UR_STANDALONE_BUILD)
Expand Down
13 changes: 12 additions & 1 deletion source/adapters/level_zero/device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1490,12 +1490,23 @@ ur_device_handle_t_::useImmediateCommandLists() {
bool isDG2OrNewer = this->isIntelDG2OrNewer();
bool isDG2SupportedDriver =
this->Platform->isDriverVersionNewerOrSimilar(1, 5, 30820);
if ((isDG2SupportedDriver && isDG2OrNewer) || isPVC()) {
// Disable immediate command lists for DG2 devices on Windows due to driver
// limitations.
bool isLinux = true;
#ifdef _WIN32
isLinux = false;
#endif
if ((isDG2SupportedDriver && isDG2OrNewer && isLinux) || isPVC() ||
isNewerThanIntelDG2()) {
return PerQueue;
} else {
return NotUsed;
}
}

logger::info("NOTE: L0 Immediate CommandList Setting: {}",
ImmediateCommandlistsSetting);

switch (ImmediateCommandlistsSetting) {
case 0:
return NotUsed;
Expand Down
5 changes: 5 additions & 0 deletions source/adapters/level_zero/device.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,11 @@ struct ur_device_handle_t_ : _ur_object {
ZeDeviceIpVersionExt->ipVersion >= 0x030dc000);
}

bool isNewerThanIntelDG2() {
return (ZeDeviceProperties->vendorId == 0x8086 &&
ZeDeviceIpVersionExt->ipVersion >= 0x030f0000);
}

bool isIntegrated() {
return (ZeDeviceProperties->flags & ZE_DEVICE_PROPERTY_FLAG_INTEGRATED);
}
Expand Down
Loading