Skip to content

Commit e39df7b

Browse files
committed
Fix compilation for latest Unified Runtime
After API change: intel/llvm#17876 Signed-off-by: Igor Chorazewicz <[email protected]>
1 parent e584fa0 commit e39df7b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

source/framework/ur/print_device_info.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,10 +124,10 @@ static void printAvailableDevices() {
124124
UrState ur;
125125

126126
uint32_t platform_count = 0;
127-
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(&ur.adapter, 1, 0, nullptr, &platform_count));
127+
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(ur.adapter, 0, nullptr, &platform_count));
128128

129129
std::vector<ur_platform_handle_t> platforms(platform_count);
130-
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(&ur.adapter, 1, platform_count, platforms.data(),
130+
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(ur.adapter, platform_count, platforms.data(),
131131
nullptr));
132132

133133
std::cout << "UR platforms: " << platform_count << std::endl;

source/framework/ur/ur.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@ UrState::UrState() {
2828
EXPECT_UR_RESULT_SUCCESS(urAdapterGet(1, &adapter, nullptr));
2929

3030
uint32_t platform_count = 0;
31-
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(&adapter, 1, 0, nullptr, &platform_count));
31+
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(adapter, 0, nullptr, &platform_count));
3232

3333
std::vector<ur_platform_handle_t> platforms(platform_count);
34-
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(&adapter, 1, platform_count, platforms.data(),
34+
EXPECT_UR_RESULT_SUCCESS(urPlatformGet(adapter, platform_count, platforms.data(),
3535
nullptr));
3636

3737
if (Configuration::get().urPlatformIndex >= platform_count) {

0 commit comments

Comments
 (0)