The OpenCL specification states that images are allocated
authorPekka Jaaskelainen <pekka.jaaskelainen@tut.fi>
Thu, 9 Jan 2014 13:37:30 +0000 (13:37 +0000)
committerPekka Jaaskelainen <pekka.jaaskelainen@tut.fi>
Thu, 9 Jan 2014 13:37:30 +0000 (13:37 +0000)
commit3587b32e1cc978d997602d4c0784cdcedda7de3f
tree22a2c896daeee817f54ffce2fafc8719256b71a3
parentaf4480a121473f7218081a38a92562c742b47dc1
The OpenCL specification states that images are allocated
from the global address space (6.5.1 of the OpenCL 1.2 specification).
This makes clang construct the image arguments in the global address
space and generate the argument metadata with the correct address space
descriptor.

Patch by Pedro Ferreira!

llvm-svn: 198868
clang/lib/CodeGen/CGOpenCLRuntime.cpp
clang/lib/CodeGen/CodeGenFunction.cpp
clang/test/CodeGenOpenCL/kernel-arg-info.cl