Skip to content

[UR] [OPENCL] sycl-ls fails to show other targets and errors if no OpenCL driver #18075

@coldav

Description

@coldav

Describe the bug

If we try sycl-ls where we have no OpenCL driver e.g. not setting OCL_ICD_FILENAMES, then it errors out with
SYCL Exception encountered: Native API failed. Native API returns: 4 (UR_RESULT_ERROR_INVALID_VALUE), despite there being a native cpu driver (dpc++ built with --native_cpu -DNATIVECPU_USE_OCK=ON). Deleting libur_adapter_opencl* then allows it to find the native cpu driver.

This appears to be due to #17572

To reproduce

Build dpc++ with --native_cpu -DNATIVECPU_USE_OCK=ON
use an OpenCL ICD but not opencl driver
sycl-ls

Environment

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions