[PATCH] D116266: [SPIR-V] Add linking of separate translation units using spirv-link

Alexey Bader via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 5 04:25:06 PDT 2022


bader added inline comments.


================
Comment at: clang/docs/UsersManual.rst:3602
 
+Linking is done using ``spirv-link`` from `the SPIRV-Tools project
+<https://github.com/KhronosGroup/SPIRV-Tools#linker>`_. Similar to other external
----------------
Anastasia wrote:
> bader wrote:
> > @Anastasia, sorry for late feedback.
> > I think being able to link SPIR-V modules is a great feature, but I have a concerns regarding `spirv-link` tool.
> > The documentation says that the linker tool is still under development and from our experience this tool had issues blocking us from using it for SYCL mode. The last time new features were added to this tool is almost 4 year ago.
> > Do you know if there are any plans for to finish the development and if ? Are you aware of any "real-world usages" of this tool? Have you tried to use it for SPIR-V module produced from C++ (e.g. C++ for OpenCL)?
> > I think supporting SPIR-V extensions like [[ https://github.com/KhronosGroup/SPIRV-Registry/blob/main/extensions/KHR/SPV_KHR_linkonce_odr.asciidoc | SPV_KHR_linkonce_odr ]] is quite important for code size and JIT compilation time reduction. As this extension was ratified recently, I suppose `spirv-link` doesn't support it yet.
> Hi Alexey,
> 
> Sorry for the late reply. Do you have any other suggestions about the tools that can be used for linking SPIR-V binaries? 
> 
> I am not in contact with the maintainers but it is an open-source project so I imagine contributions to enhance or improve functionality should be welcome... unless you have other experiences?
> 
> Do you have any other suggestions about the tools that can be used for linking SPIR-V binaries?

I'm unaware of other tools for SPIR-V binaries linking. To link SPIR-V binaries in our toolchain, we translate them to/from LLVM IR to link LLVM IR.

> I am not in contact with the maintainers but it is an open-source project so I imagine contributions to enhance or improve functionality should be welcome... unless you have other experiences?

I talked to the maintainers (but it was quite long time ago) and they told me that there are no active contributors to this tool.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D116266/new/

https://reviews.llvm.org/D116266



More information about the cfe-commits mailing list