[clang] [llvm] [HIPSPV] Add in-tree SPIR-V backend support for chipStar (PR #186972)
Henry Linjamäki via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 9 05:47:01 PDT 2026
================
@@ -59,7 +59,11 @@ void HIPSPV::Linker::constructLinkAndEmitSpirvCommand(
// Link LLVM bitcode.
ArgStringList LinkArgs{};
- for (auto Input : Inputs)
+ // The new offload driver can pass non-filename InputInfo entries (e.g.
+ // Nothing/InputArg placeholders) alongside the real bitcode inputs. Calling
+ // getFilename() on those reads garbage from the union; only forward genuine
+ // filename inputs to llvm-link.
+ for (const auto &Input : Inputs)
if (Input.isFilename())
LinkArgs.push_back(Input.getFilename());
----------------
linehill wrote:
This change got introduced in https://github.com/llvm/llvm-project/pull/187655 so a rebase maybe needed before merge.
https://github.com/llvm/llvm-project/pull/186972
More information about the cfe-commits
mailing list