[PATCH] D128441: [CUDA] Do not embed a fatbinary when using the new driver

Joseph Huber via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 23 11:04:58 PDT 2022


jhuber6 added a comment.

In D128441#3605809 <https://reviews.llvm.org/D128441#3605809>, @tra wrote:

>> The linker wrapper cannot do anything with these embedded PTX files because we do not know how to link them,
>
> Neither, apparently does `nvlink`. It does have `--emip-ptx <file>` option, but only if LTO is enabled, which matches the new driver behavior.

Thanks for the review. I'm not sure exactly how CUDA does it, but for their RDC support they do somehow link PTX from multiple TU's at runtime for JIT. I'm guessing they just compile each file upon initialization and link them with nvlink. I think using LTO for JIT support is the saner option in that case.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D128441



More information about the cfe-commits mailing list