llvm icon indicating copy to clipboard operation
llvm copied to clipboard

[UR] Mechanism for adapter filtering during loader initialization

Open kswiecicki opened this issue 4 months ago • 1 comments

Is your feature request related to a problem? Please describe

The L0 V2 adapter should be enabled by default on newer platforms. To implement this, we need to determine platform compatibility during the adapter load phase.

Platform identification in L0 adapter case requires:

  • Loading the L0 driver
  • Executing the function sequence: zeInit()->zeDriverGet()->zeDeviceGetProperties()

Describe the solution you would like

The most straightforward approach is to:

  1. Temporarily load the driver
  2. Query the necessary platform information
  3. Unload based on the results

Image

UR loader can access the necessary function through ur_loader::LibLoader::getFunctionPtr() and execute the retrieved function to validate platform compatibility.

Describe alternatives you have considered

No response

Additional context

No response

kswiecicki avatar Jun 12 '25 11:06 kswiecicki