add --opencl-embed-kernel-code option
commitbcd9c4d3251d5ecdbe4e5002a0faeb737da5d382
authorSven van Haastregt <sven.vanhaastregt@arm.com>
Wed, 13 Aug 2014 16:25:25 +0000 (13 17:25 +0100)
committerSven Verdoolaege <skimo@kotnet.org>
Thu, 14 Aug 2014 06:49:40 +0000 (14 08:49 +0200)
tree006af35bf7ad2d452ab7059c74f087713a14d1a1
parent0c298ab7f0e85255d2f5fee62d708232ec032f04
add --opencl-embed-kernel-code option

With this option, the kernel code is written to the kernel.cl file as a
string literal.  The kernel.cl file is then #included in the host file
such that the kernel.cl file is not needed at run time anymore.

The kernel string literal may become large if there are many kernels,
and some compilers may impose a limit on the size of string literals.
However, Clang (2.9, 3.4) and gcc (4.4, 4.6, 4.7) seem to compile a
128-kilobyte string literal without any problems.

Signed-off-by: Sven van Haastregt <sven.vanhaastregt@arm.com>
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
README
opencl.c
opencl_test.sh.in
ppcg_options.c
ppcg_options.h