[clang] [Clang][SYCL] Introduce clang-sycl-link-wrapper to link SYCL offloading device code (Part 1 of many) (PR #112245)
Joseph Huber via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 15 15:52:21 PDT 2024
jhuber6 wrote:
> It seems to me like this should be done through the LTO interface and driven through `lld`. I can understand if an intermediate step is required while the SPIR-V backend is under development, but clang shouldn't be in the business of linking, and generally neither should llvm-link.
>
> I'd be curious for @MaskRay's perspective too.
I don't think `lld` makes sense, but you can definitely use the LTO interface inside of this tool to create a similar effect. That should also get rid of the need for this `--device-library` thing because then it'll just internalize anything that's unused. That is, if the SYCL folks write their runtimes correctly with hidden visibility on device functions.
https://github.com/llvm/llvm-project/pull/112245
More information about the cfe-commits
mailing list