[PATCH] D13105: [OpenCL] Enable program scope variables for OpenCL2.0
Anastasia via cfe-commits
cfe-commits at lists.llvm.org
Wed Sep 23 09:34:52 PDT 2015
Anastasia created this revision.
Anastasia added a reviewer: pekka.jaaskelainen.
Anastasia added a subscriber: cfe-commits.
I would like to commit this change that enables program scope variables (PSVs) – an OpenCL2.0 feature (Section 6.5.1).
There are three major changes in this patch.
First change removes virtual SC_OpenCLWorkGroupLocal storage type specifier as it conflicts with static
local variables now and prevents diagnosing static local address space variables correctly. Also it doesn’t seem really
necessary since we can identify local AS variable by looking at the AS attribute itself.
Second change makes static local variables as well as global variables allowed in OpenCL2.0 (OpenCL2.0 s6.8 and s6.5.1).
Last change improves diagnostics of allowed ASes for variables in different scopes:
Global or static local variables have to be in global or constant ASes (OpenCL1.2 s6.5, OpenCL2.0 s6.5.1);
Non-kernel function variables can’t be declared in local or constant ASes (OpenCL1.1 s6.5.2 and s6.5.3).
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 11072 bytes
Desc: not available
More information about the cfe-commits