llvm icon indicating copy to clipboard operation
llvm copied to clipboard

[SYCL] Support sycl::kernel_bundle for multi-device scenario

Open againull opened this issue 1 year ago • 0 comments

This PR includes:

  • Changes in the program manager methods to be able to properly create/build UR program for multiple devices. So far, we were mostly using only the first device in the vector to create/build UR program which made UR program unusable on other devices.

  • UR tag update brings the version of urProgramCreateWithBinary which allows to create UR program from multiple device binaries.

  • Our program cache key allowed only a single device. I have changed it to contain a set of devices. If UR program is created and built for a set of devices then the same UR program is usable whenver we have any subset of this set. That's why if we have a program built for a set of devices then add all subsets to the cache. Before we were adding a record to the cache for each device from the set which is incorrect. For example, if someone requests a UR program for {dev2, dev3} from the cache then it is expected that this UR progam must be usable to submit a kernel to dev3. But we could get a program for {dev1, dev2} from the cache which is unusable on dev3.

againull avatar Sep 28 '24 00:09 againull