In preparation for accepting other offloading kinds with the new driver,
this patch makes the way we handle offloading actions more generic. A
new field to get the associated device action's toolchain is used rather
than manually iterating a list. This makes building the arguments easier
and makes sure that we doin't rely on any implicit ordering.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/lib/Driver/ToolChains/Clang.cpp | ||
---|---|---|
6949–6952 | Linux path may contain ',' which cannot be passed by this option. We've seen similar issues with -inputs= option of clang-offload-bundler. To solve that issue, we had to add support of multiple -input= options. |
clang/lib/Driver/ToolChains/Clang.cpp | ||
---|---|---|
6949–6952 | Ugh, you could probably split this starting from the end since we assume it will always end with at least three commas, but that's not a satisfying solution. I've been pondering creating a new tool to do this, but haven't quite decided how that should look. I'd imagine it would basically behave like how we invoke fatbinary. This issue isn't related to this patch, so I'll probably just parse it in reverse upstream, thanks for bringing this up. |
clang/lib/Driver/ToolChains/Clang.cpp | ||
---|---|---|
6949–6952 | I agree the issue is orthogonal to this patch. Parsing backward is an option. Another option is to put file name at the end of the option. Maybe the latter is less confusing. |
Linux path may contain ',' which cannot be passed by this option.
We've seen similar issues with -inputs= option of clang-offload-bundler. To solve that issue, we had to add support of multiple -input= options.