[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)
Tom Honermann via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 23 10:37:00 PDT 2025
================
@@ -12251,6 +12264,9 @@ bool Sema::CheckFunctionDeclaration(Scope *S, FunctionDecl *NewFD,
if (NewFD->hasAttr<SYCLKernelEntryPointAttr>())
SYCL().CheckSYCLEntryPointFunctionDecl(NewFD);
+ if (NewFD->hasAttr<SYCLExternalAttr>())
+ SYCL().CheckSYCLExternalFunctionDecl(NewFD);
----------------
tahonermann wrote:
The checks include checking for linkage which I don't think is necessarily computed at the time the attribute is visited.
https://github.com/llvm/llvm-project/pull/140282
More information about the cfe-commits
mailing list