This revision was automatically updated to reflect the committed changes.
Closed by commit rC343611: [HIP] Support early finalization of device code for
-fno-gpu-rdc (authored by yaxunl, committed by ).
Repository:
rC Clang
https://reviews.llvm.org/D52377
Files:
include/clang/Basic/LangOpti
tra accepted this revision.
tra added a comment.
This revision is now accepted and ready to land.
LGTM.
https://reviews.llvm.org/D52377
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit
yaxunl updated this revision to Diff 167952.
yaxunl edited the summary of this revision.
yaxunl added a comment.
Added -f{no}-cuda-rdc as alias to -f{no}-gpu-rdc.
https://reviews.llvm.org/D52377
Files:
include/clang/Basic/LangOptions.def
include/clang/Driver/Options.td
include/clang/Drive
tra added inline comments.
Comment at: include/clang/Driver/Options.td:587-589
+def fgpu_rdc : Flag<["-"], "fgpu-rdc">, Flags<[CC1Option]>,
HelpText<"Generate relocatable device code, also known as separate
compilation mode.">;
+def fno_gpu_rdc : Flag<["-"], "fno-gpu-rdc">;
-
yaxunl updated this revision to Diff 167774.
yaxunl retitled this revision from "[HIP] Support early finalization of device
code" to "[HIP] Support early finalization of device code for -fno-gpu-rdc".
yaxunl edited the summary of this revision.
yaxunl added a comment.
Uses -fno-gpu-rdc for early
yaxunl added a comment.
In https://reviews.llvm.org/D52377#1242547, @tra wrote:
> Overall the patch look OK. I'll take a closer look on Monday.
>
> Which mode do you expect will be most commonly used for HIP by default? With
> this patch we'll have two different ways to do similar things in HIP
tra added a comment.
Overall the patch look OK. I'll take a closer look on Monday.
Which mode do you expect will be most commonly used for HIP by default? With
this patch we'll have two different ways to do similar things in HIP vs. CUDA.
E.g. by default CUDA compiles GPU code in each TU in a co
yaxunl updated this revision to Diff 166556.
yaxunl added a comment.
Fix comments.
https://reviews.llvm.org/D52377
Files:
include/clang/Driver/Options.td
include/clang/Driver/Types.def
lib/CodeGen/CGCUDANV.cpp
lib/Driver/Driver.cpp
lib/Driver/ToolChains/Clang.cpp
lib/Driver/ToolChai
yaxunl created this revision.
yaxunl added a reviewer: tra.
This patch introduced a driver option `--hip-early-finalize`. When enabled,
clang will assume the device code in each translation unit does not call
external functions except those in the device library, therefore it is possible
to compil