Commit Graph

6 Commits

Author SHA1 Message Date
Anastasia Stulova 88ed70e247 [OpenCL] Rename lang mode flag for C++ mode
Rename lang mode flag to -cl-std=clc++/-cl-std=CLC++
or -std=clc++/-std=CLC++.

This aligns with OpenCL C conversion and removes ambiguity
with OpenCL C++. 

Differential Revision: https://reviews.llvm.org/D65102

llvm-svn: 367008
2019-07-25 11:04:29 +00:00
Anastasia Stulova f61b5481fd [OpenCL] Fix OpenCL/SPIR version metadata in C++ mode.
C++ is derived from OpenCL v2.0 therefore set the versions
identically.

Differential Revision: https://reviews.llvm.org/D62657

llvm-svn: 362102
2019-05-30 15:18:07 +00:00
Alexey Bader 364a11651e [OpenCL] Fix OpenCL and SPIR version metadata generation.
Summary: OpenCL and SPIR version metadata must be generated once per module instead of once per mangled global value.

Reviewers: Anastasia, yaxunl

Reviewed By: Anastasia

Subscribers: ahatanak, cfe-commits

Differential Revision: https://reviews.llvm.org/D34235

llvm-svn: 305796
2017-06-20 14:30:18 +00:00
Alexey Bader b3190829e5 [OpenCL] Fix SPIR version generation.
Patch by Egor Churaev (echuraev).

Reviewers: Anastasia

Subscribers: bader, yaxunl, cfe-commits

Differential Revision: https://reviews.llvm.org/D27300

llvm-svn: 288890
2016-12-07 08:38:24 +00:00
Yaxun Liu f2e8ab2566 [OpenCL] Fixes bug of missing OCL version metadata on the AMDGCN target
Added the opencl.ocl.version metadata to be emitted with amdgcn. Created a static function emitOCLVerMD which is shared between triple spir and target amdgcn.

Also added new testcases to existing test file, spir_version.cl inside test/CodeGenOpenCL.

Patch by Aaron En Ye Shi.

Differential Revision: https://reviews.llvm.org/D22424

llvm-svn: 276010
2016-07-19 19:39:45 +00:00
Xiuli Pan 972bea8a2e [OpenCL] Add ocl and spir version for spir target
Summary: Add opencl.spir.version and opencl.ocl.version metadata for CodeGen to identify OpenCL version. 

Reviewers: yaxunl, Anastasia

Subscribers: cfe-commits, pekka.jaaskelainen

Differential Revision: http://reviews.llvm.org/D17596

llvm-svn: 264241
2016-03-24 03:57:17 +00:00