llvm-project/clang/test/SemaOpenCL
Alexey Bader c813c8113d [OpenCL] Fix access qualifiers handling for typedefs
OpenCL s6.6: "Access qualifier must be used with image object arguments
of kernels and of user-defined functions [...] If no qualifier is
provided, read_only is assumed".

This does not define the behavior for image types used in typedef
declaration, but following the spec logic, we should allow access
qualifiers specification in typedefs, e.g.:

  typedef write_only image1d_t img1d_wo;

Unlike cv-qualifiers, user cannot add access qualifier to a typedef
type, i.e. this is not allowed:

  typedef image1d_t img1d; // note: previously declared 'read_only' here
  void foo(write_only img1d im) {} // error: multiple access qualifier

Patch by Andrew Savonichev.
Reviewers: Anastasia Stulova.

Differential revision: http://reviews.llvm.org/D20948

llvm-svn: 274858
2016-07-08 15:34:59 +00:00
..
access-qualifier.cl [OpenCL] Fix access qualifiers handling for typedefs 2016-07-08 15:34:59 +00:00
address-spaces-conversions-cl2.0.cl PR19957: [OpenCL] Incorrectly accepts implicit address space conversion with ternary operator. 2016-04-12 19:43:36 +00:00
address-spaces.cl
amdgpu-num-register-attrs.cl Workaround attribute ordering issue with kernel only attributes 2014-12-05 18:03:58 +00:00
array-parameters.cl
as_type.cl [OpenCL] Fix __builtin_astype for vec3 types. 2016-06-08 15:11:21 +00:00
bool-vectors.cl [Sema] Make extended vectors of `bool` an error. 2016-01-28 01:38:18 +00:00
builtin.cl [OpenCL] Disable C99 standard lib functions 2016-02-12 12:07:04 +00:00
cl20-device-side-enqueue.cl [OpenCL] An implementation of device side enqueue (DSE) from OpenCL v2.0 s6.13.17. 2016-07-05 11:31:24 +00:00
clang-builtin-version.cl [OpenCL] Make OpenCL Builtins added according to the right version. 2016-07-04 16:07:18 +00:00
cond.cl [OpenCL] Disallow taking an address of a function. 2016-01-05 14:39:27 +00:00
endian-attr.cl
event_t.cl [OpenCL] Allow explicit cast of 0 to event_t. 2016-05-20 17:18:16 +00:00
event_t_overload.cl
extension-version.cl Disable warning about core features by default 2016-06-01 18:04:53 +00:00
extensions.cl [OpenCL] Add supported OpenCL extensions to target info. 2016-05-16 17:06:34 +00:00
extern.cl Update clang for D20348 2016-06-14 21:02:05 +00:00
func_ptr.cl [OpenCL] Disallow taking an address of a function. 2016-01-05 14:39:27 +00:00
half.cl [OpenCL] Add supported OpenCL extensions to target info. 2016-05-16 17:06:34 +00:00
images.cl [OpenCL] Complete image types support. 2016-04-08 13:40:33 +00:00
init.cl
invalid-block.cl Block: Fix a crash when we have type attributes or qualifiers with omitted 2016-04-18 18:40:51 +00:00
invalid-constant.cl
invalid-image.cl [OpenCL] Complete image types support. 2016-04-08 13:40:33 +00:00
invalid-kernel-attrs.cl [OpenCL] Refine OpenCLImageAccessAttr to OpenCLAccessAttr 2016-02-26 03:13:03 +00:00
invalid-kernel-parameters.cl [OpenCL] Add supported OpenCL extensions to target info. 2016-05-16 17:06:34 +00:00
invalid-kernel.cl
invalid-logical-ops-1.1.cl
invalid-logical-ops-1.2.cl Disable warning about core features by default 2016-06-01 18:04:53 +00:00
invalid-pipe-builtin-cl2.0.cl [OpenCL] Fix pipe builtin bugs 2016-03-30 04:46:32 +00:00
invalid-pipes-cl2.0.cl [OpenCL] Fix pipe type dump. 2016-05-03 05:37:07 +00:00
lit.local.cfg
nosvm.cl [OpenCL] Added nosvm attribute for OpenCL v2.0. 2016-03-31 11:07:22 +00:00
null_literal.cl [OpenCL 2.0] In OpenCL v2.0 s6.5 all pointers are implicitly in generic 2015-12-11 17:41:19 +00:00
pipes-1.2-negative.cl [OpenCL] Pipe type support 2016-01-09 12:53:17 +00:00
sampler_t.cl [OpenCL] Apply missing restrictions for Blocks in OpenCL v2.0 2016-03-03 13:33:19 +00:00
sampler_t_overload.cl
shifts.cl Restores r228382, which was reverted in r228406. 2015-02-25 05:48:23 +00:00
sizeof.cl
storageclass-cl20.cl [OpenCL] Improve diagnostics of address spaces for variables in function 2016-03-03 18:38:40 +00:00
storageclass.cl [OpenCL] Output OpenCL version in diagnostics. 2016-05-12 16:28:25 +00:00
str_literals.cl
to_addr_builtin.cl [OpenCL] Make OpenCL Builtins added according to the right version. 2016-07-04 16:07:18 +00:00
unroll-hint.cl [OpenCL] Generate metadata for opencl_unroll_hint attribute 2016-02-19 18:30:11 +00:00
unsupported.cl [OpenCL] Adding reserved operator logical xor for OpenCL 2016-02-03 15:17:14 +00:00
vec_compare.cl
vec_step.cl
vector_conv_invalid.cl
vector_inc_dec_ops.cl
vector_literals_const.cl
vector_literals_invalid.cl
warn-missing-prototypes.cl