Skip to content

Commit 470e3aa

Browse files
winstonzhang-intelAlexeySachkov
authored andcommitted
[UR][L0] urBindlessImagesGetImageMemoryHandleTypeSupportExp correction (#19667)
VK_FORMAT_R8G8B8A8_UNORM is supported on L0 urt, correction to verifyCommonImagePropertiesSupport. --------- Signed-off-by: Zhang, Winston <[email protected]>
1 parent 9c8d1d7 commit 470e3aa

File tree

3 files changed

+12
-11
lines changed

3 files changed

+12
-11
lines changed

sycl/test-e2e/bindless_images/dx11_interop/read_write_unsampled.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,10 @@ int runTest(D3D11ProgramState &d3d11ProgramState, sycl::queue syclQueue,
213213
// E.g. LevelZero does not support `unorm` channel types.
214214
if (!bindless_helpers::memoryAllocationSupported(
215215
syclImageDesc, syclexp::image_memory_handle_type::opaque_handle,
216-
syclQueue)) {
216+
syclQueue) ||
217+
(channelType == sycl::image_channel_type::unorm_int8 &&
218+
syclQueue.get_device().get_backend() ==
219+
sycl::backend::ext_oneapi_level_zero)) {
217220
// We cannot allocate the image memory, skip the test.
218221
#ifdef VERBOSE_PRINT
219222
std::cout << "Memory allocation unsupported. Skipping test.\n";

sycl/test-e2e/bindless_images/dx12_interop/read_write_unsampled.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -523,6 +523,14 @@ static bool
523523
runTest(DX12SYCLDevice &device, sycl::image_channel_type channelType,
524524
sycl::range<NDims> globalSize, sycl::range<NDims> localSize) {
525525

526+
// Skip unorm_int8 tests for Level Zero backend
527+
if (channelType == sycl::image_channel_type::unorm_int8 &&
528+
device.getSyclQueue().get_device().get_backend() ==
529+
sycl::backend::ext_oneapi_level_zero) {
530+
std::cout << "Skipping unorm_int8 test for Level Zero backend.\n";
531+
return true;
532+
}
533+
526534
syclexp::image_descriptor syclImageDesc{globalSize, NChannels, channelType};
527535

528536
// Verify ability to allocate the above image descriptor.

unified-runtime/source/adapters/level_zero/image_common.cpp

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1016,16 +1016,6 @@ bool verifyCommonImagePropertiesSupport(
10161016
}
10171017
}
10181018

1019-
// Verify unnormalized channel type support.
1020-
// LevelZero currently doesn't support unnormalized channel types.
1021-
switch (pImageFormat->channelType) {
1022-
default:
1023-
break;
1024-
case UR_IMAGE_CHANNEL_TYPE_UNORM_INT8:
1025-
case UR_IMAGE_CHANNEL_TYPE_UNORM_INT16:
1026-
return false;
1027-
}
1028-
10291019
return supported;
10301020
}
10311021

0 commit comments

Comments
 (0)