[PATCH] D117137: [Driver] Add CUDA support for --offline param
Artem Belevich via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 20 10:54:42 PST 2022
tra added a comment.
LGTM in general, modulo few nits.
Nit: looks like the changes need some clang-formatting.
================
Comment at: clang/lib/Driver/Driver.cpp:112
default:
- D.Diag(diag::err_drv_only_one_offload_target_supported_in) << "HIP";
+ D.Diag(diag::err_drv_only_one_offload_target_supported_in) << "";
return llvm::None;
----------------
You either need to rephrase the diag message in clang/include/clang/Basic/DiagnosticDriverKinds.td and remove the argument, or provide the "CUDA" or "HIP" as the argument. Passing a "" as is will result in an incomplete sentence.
================
Comment at: clang/lib/Driver/Driver.cpp:141-142
+ if (!Args.hasArg(options::OPT_offload_EQ)) {
+ static const llvm::Triple T("amdgcn-amd-amdhsa"); // Default HIP triple.
+ return T;
+ }
----------------
Just `return llvm::Triple("amdgcn-amd-amdhsa")` ?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D117137/new/
https://reviews.llvm.org/D117137
More information about the cfe-commits
mailing list