Skip to content

[SYCL][Bindless][UR][E2E] Add image memory and handle support queries #17865

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 26 commits into from
May 2, 2025

Conversation

przemektmalon
Copy link
Contributor

@przemektmalon przemektmalon commented Apr 4, 2025

This patch introduces two new SYCL queries for Bindless Images.

get_image_memory_support returns a vector of supported image backing memory types for a device given an `image_descriptor.

is_image_handle_supported returns a boolean indicating whether the device supports creation of either a sampled_image_handle or unsampled_image_handle, given an image_descriptor and image backing memory type.

Some tests are updated to use these queries to filter out unsupported image properties, e.g. allocating unorm channel types on the LevelZero backend.

Additionally some fixes are made to the UR HIP device queries that pertain to supported image properties.

The HIP queries for UR_DEVICE_INFO_IMAGE<N>D_MAX_<WIDTH/HEIGHT/DEPTH> have been amended to remove redundant calls to hipDeviceGetAttribute (as this was being called twice unnecessarily, with the same query parameter).

The HIP queries for UR_DEVICE_INFO_MAX_IMAGE_LINEAR_<WIDTH/HEIGHT/PITCH>_EXP have been amended to return plausible values for the HIP backend (instead of returning 1 for each of these).

This patch introduces two new SYCL queries for Bindless Images.

`get_image_memory_support` returns a vector of supported image backing
memory types for a device given an `image_descriptor.

`get_image_handle_supported` returns a boolean indicating whether the
device supports creation of either a `sampled_image_handle` or
`unsampled_image_handle`, given an `image_descriptor` and image backing
memory type.

Some tests are updated to use these queries to filter out unsupported
image properties, e.g. allocating `unorm` channel types on the LevelZero
backend.
Copy link
Contributor

@hvdijk hvdijk left a comment

Choose a reason for hiding this comment

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

The NativeCPU part looks fine.

@przemektmalon przemektmalon changed the title Add image memory and handle support queries [SYCL][Bindless][UR}Add image memory and handle support queries Apr 7, 2025
@przemektmalon przemektmalon changed the title [SYCL][Bindless][UR}Add image memory and handle support queries [SYCL][Bindless][UR] Add image memory and handle support queries Apr 7, 2025
@przemektmalon przemektmalon changed the title [SYCL][Bindless][UR] Add image memory and handle support queries [SYCL][Bindless][UR][E2E] Add image memory and handle support queries Apr 7, 2025
@przemektmalon
Copy link
Contributor Author

Ping @intel/llvm-reviewers-runtime @intel/unified-runtime-reviewers-level-zero

@przemektmalon
Copy link
Contributor Author

@intel/llvm-gatekeepers This should be ready to merge. I believe all review groups have approved. Sean's request for changes has been addressed and should not be a blocker for merging this PR.

@martygrant martygrant merged commit 0128832 into intel:sycl May 2, 2025
34 checks passed
aelovikov-intel added a commit to aelovikov-intel/llvm that referenced this pull request Jul 1, 2025
I've updated all the known uses when it was introduced in
intel#18168 but then
intel#17865 added code that didn't use
them.
aelovikov-intel added a commit that referenced this pull request Jul 2, 2025
I've updated all the known uses when it was introduced in
#18168 but then
#17865 added code that didn't use the
helper.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants