ABataev added inline comments.

================
Comment at: clang/include/clang/Driver/Options.td:3411-3413
+// C++ SYCL options
+def fsycl : Flag<["-"], "fsycl">, Group<sycl_Group>,
+  HelpText<"Enable SYCL kernels compilation for device">;
----------------
Usually, we add a pair of such flags, `-fsycl` and `fno-sycl` to have the 
explicit way to disable some functionality.


================
Comment at: clang/lib/Driver/ToolChains/Clang.cpp:4014-4016
+  if (IsSYCL) {
+    CmdArgs.push_back("-fsycl-is-device");
+  }
----------------
No need for braces here


================
Comment at: clang/test/Driver/sycl.c:5
+
+// DEFAULT: "-fsycl-is-device"
----------------
I would add a check that this flag is found on clang invocation with `-cc1` 
option (i.e. it is passed to the frontend)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D74048/new/

https://reviews.llvm.org/D74048



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to