Skip to content

Conversation

@uditagarwal97
Copy link
Contributor

@uditagarwal97 uditagarwal97 commented May 31, 2024

Example sycl-ls --verbose output:

...
Platform [#1]:
    Version  : 1.3
    Name     : Intel(R) Level-Zero
    Vendor   : Intel(R) Corporation
    Devices  : 1
        Type              : gpu
        Version           : 12.60.7
        Name              : Intel(R) Data Center GPU Max 1550
        Vendor            : Intel(R) Corporation
        Driver            : 1.3.26918
        UUID              : 1341282141147000580000000
        Num SubDevices    : 2
        Num SubSubDevices : 8
        Aspects           : gpu fp16 fp64 ...

if (Device.has(aspect::ext_intel_device_info_uuid)) {
auto UUID = Device.get_info<sycl::ext::intel::info::device::uuid>();
std::cout << Prepend << "UUID : ";
for (int i = 0; i < 16; i++) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Should you be using ZE_MAX_DEVICE_UUID_SIZE instead of assuming size is 16

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

If it is documented as 16 then ok.

Copy link

Choose a reason for hiding this comment

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

Or just use a range-based for loop on UUID

@@ -0,0 +1,15 @@
/* Test to check that sycl-ls is outputting UUID and number of sub and sub-sub
* devices. */
// REQUIRES: gpu, level_zero
Copy link
Contributor

Choose a reason for hiding this comment

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

will this work on Gen12 ? Or is it PVC only?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It should work on Gen12 as well. The test passes on Gen12 precommit: https://github.com/intel/llvm/actions/runs/9343215312/job/25714501971

@uditagarwal97
Copy link
Contributor Author

Pre commit failure in Linux Gen12 is in BFloat16/bfloat16_builtins.cpp E2E test which is unrelated to this PR and reported in #13790

@uditagarwal97
Copy link
Contributor Author

@intel/llvm-gatekeepers The PR is ready!

@steffenlarsen steffenlarsen merged commit 82ebc23 into intel:sycl Jun 4, 2024
@uditagarwal97 uditagarwal97 deleted the sycl_ls_info branch November 5, 2025 20:19
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.

6 participants