One of the goal of C++ mode for OpenCL is to preserve backwards compatibility with OpenCL C v2.0!
This patch enables all OpenCL C types and extensions in C++!
Paths
| Differential D57824
[OpenCL][PR40603] In C++ preserve backwards compatibility with OpenCL C v2.0 ClosedPublic Authored by Anastasia on Feb 6 2019, 8:47 AM.
Details
Summary One of the goal of C++ mode for OpenCL is to preserve backwards compatibility with OpenCL C v2.0! This patch enables all OpenCL C types and extensions in C++!
Diff Detail Event Timeline
Anastasia added inline comments.
Anastasia retitled this revision from [OpenCL][PR40603] Align the use of extensions in C++ to be backwards compatible with OpenCL C v2.0 to [OpenCL][PR40603] In C++ preserve backwards compatibility with OpenCL C v2.0. Comment Actions
This revision is now accepted and ready to land.Feb 7 2019, 8:12 AM Closed by commit rL353431: [OpenCL][PR40603] In C++ preserve compatibility with OpenCL C v2.0 (authored by stulova). · Explain WhyFeb 7 2019, 9:32 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 185564 lib/Frontend/InitPreprocessor.cpp
lib/Parse/ParsePragma.cpp
lib/Sema/Sema.cpp
test/SemaOpenCL/extension-version.cl
test/SemaOpenCL/extensions.cl
|
Why not set OpenCLVersion in lib/Frontend/CompilerInvocation.cpp instead? Then you wouldn't have to "override" the version in multiple places (which increases the risk of missing one or more places).