[PATCH] D143849: [Clang][OpenCL] Allow pointers in structs as kernel arguments from 2.0

Yaxun Liu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Feb 13 07:53:47 PST 2023


yaxunl added inline comments.


================
Comment at: clang/test/SemaOpenCL/invalid-kernel-parameters.cl:90
 
+#if __OPENCL_C_VERSION__ <= CL_VERSION_1_2
 typedef struct FooImage2D // expected-note{{within field of type 'FooImage2D' declared here}}
----------------
we should not limit the tests to CL1.2. We should test them with 2.0 to make sure there is no diagnostics.

To differentiate between 1.2 and 2.0 you can use -verify=ocl12 and -verify=ocl20.

same as below


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D143849



More information about the cfe-commits mailing list