[PATCH] D72857: [SYCL] Driver option to enable SYCL mode and select SYCL version
Alexey Bader via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 16 10:13:26 PST 2020
bader created this revision.
Herald added subscribers: cfe-commits, Anastasia, ebevhan.
Herald added a project: clang.
User can select the version of SYCL the compiler will
use via the flag -sycl-std, similar to -cl-std.
The flag defines the LangOpts.SYCLVersion option to the
version of SYCL. The default value is undefined.
If driver is building SYCL code, flag is set to the default SYCL
version (1.2.1)
The preprocessor uses this variable to define CL_SYCL_LANGUAGE_VERSION macro,
which should be defined according to SYCL 1.2.1 standard.
Only valid value at this point for the flag is 1.2.1.
Co-Authored-By: David Wood <Q0KPU0H1YOEPHRY1R2SN5B5RL at david.davidtw.co>
Signed-off-by: Ruyman Reyes <ruyman at codeplay.com>
Signed-off-by: Alexey Bader <alexey.bader at intel.com>
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D72857
Files:
clang/include/clang/Basic/LangOptions.def
clang/include/clang/Basic/LangOptions.h
clang/include/clang/Driver/Options.td
clang/lib/Driver/ToolChains/Clang.cpp
clang/lib/Frontend/CompilerInvocation.cpp
clang/lib/Frontend/InitPreprocessor.cpp
clang/test/Driver/sycl.c
clang/test/Preprocessor/sycl-macro.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D72857.238538.patch
Type: text/x-patch
Size: 6732 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200116/7778ceaf/attachment.bin>
More information about the cfe-commits
mailing list