This revision was automatically updated to reflect the committed changes.
yaxunl marked an inline comment as done.
Closed by commit rG1eaad01046c8: [CUDA][HIP] Let lambda be host device by
default (authored by yaxunl).
Herald added a project: clang.
Repository:
rG LLVM Github Monorepo
CHANGES
tra accepted this revision.
tra added a comment.
LGTM.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78655/new/
https://reviews.llvm.org/D78655
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
yaxunl marked 3 inline comments as done.
yaxunl added inline comments.
Comment at: clang/lib/Sema/SemaCUDA.cpp:757-759
+ // In host compilation, deferred diagnostics are only emitted for functions
+ // which are sure to be emitted on host side since there is no reliable
+ //
yaxunl updated this revision to Diff 276417.
yaxunl added a comment.
revised by Artem's comments
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78655/new/
https://reviews.llvm.org/D78655
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
clang/include/clang/Sema/Sema.h
tra added inline comments.
Comment at: clang/lib/Sema/SemaCUDA.cpp:757-759
+ // In host compilation, deferred diagnostics are only emitted for functions
+ // which are sure to be emitted on host side since there is no reliable
+ // way to check if a function is emitted on
yaxunl updated this revision to Diff 276211.
yaxunl added a comment.
refactor CUDACheckLambdaCapture and add comments
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78655/new/
https://reviews.llvm.org/D78655
Files:
clang/include/clang/Basic/DiagnosticSemaKinds.td
tra added inline comments.
Comment at: clang/lib/Sema/SemaLambda.cpp:1783
+
+ if (LangOpts.CUDA && LangOpts.CUDAIsDevice)
+CUDACheckLambdaCapture(CallOperator, From);
yaxunl wrote:
> tra wrote:
> > I would expect Sema-level diags to be produced
yaxunl marked 10 inline comments as done.
yaxunl added inline comments.
Comment at: clang/lib/Sema/SemaCUDA.cpp:750
+bool Sema::CUDACheckLambdaCapture(CXXMethodDecl *Callee,
+ const sema::Capture ) {
tra wrote:
> What does the
yaxunl updated this revision to Diff 274774.
yaxunl marked 4 inline comments as done.
yaxunl added a comment.
revised by Artem's and Paul's comments
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78655/new/
https://reviews.llvm.org/D78655
Files:
pfultz2 added inline comments.
Comment at: clang/test/SemaCUDA/lambda.cu:27
+
+kernel<<<1,1>>>([&](){ hd(b); });
+// dev-error@-1 {{capture host side class data member by this pointer in
device or host device lambda function}}
Will this still produce
tra added inline comments.
Comment at: clang/lib/Sema/SemaCUDA.cpp:750
+bool Sema::CUDACheckLambdaCapture(CXXMethodDecl *Callee,
+ const sema::Capture ) {
What does the return value mean? We don't seem to check it anyways. If
yaxunl updated this revision to Diff 274589.
yaxunl retitled this revision from "[CUDA][HIP] Let non-caputuring lambda be
host device" to "[CUDA][HIP] Let lambda be host device by default".
yaxunl edited the summary of this revision.
yaxunl added a comment.
Added diagnostics for capturing host
12 matches
Mail list logo