[clang] [clang][SYCL Upstreaming] Add sycl_external attribute and restrict emitting device code (PR #140282)

via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 10 14:06:15 PDT 2025


================
@@ -29,21 +29,10 @@ int foo() {
 }
 
 template <typename Name, typename Func>
-__attribute__((sycl_kernel)) void kernel_single_task(const Func &kernelFunc) {
+[[clang::sycl_external]] void kernel_single_task(const Func &kernelFunc) {
----------------
schittir wrote:

Agreed. It should have been [[clang::sycl_kernel_entry_point(Name)]]

https://github.com/llvm/llvm-project/pull/140282


More information about the cfe-commits mailing list