OpenCL Code Generator
Description
The OpenCL Code Generator synthesizes a DAL system so that it can be executed on top of any OpenCL-capable platform. It uses a systematic approach to exploit the multiple levels of hardware parallelism of heterogeneous OpenCL platforms.
As an OpenCL program must have fixed-size input and output arrays, only processes reading and writing a fixed number of tokens in every execution of the fire
function are eligible to be executed on top of OpenCL. However, processes that do not fulfill this requirement can still be executed as native POSIX threads on the CPU.
Besides reading and writing a fixed number of tokens in every execution of the fire
function, processes mapped onto OpenCL must use the Windowed FIFO communication interface, shall not use file input or output, and not use recursive function call. More details on the restrictions that arise from the OpenCL back-end are described here. If system headers are used that are not support in OpenCL, they are ignored by the code generator automatically.
Requirements
- C/C++ environment (g++ version 4.3 or greater)
- C POSIX library
- OpenCL 1.2 library (e.g., Intel SDK for OpenCL Applications 2013 or an OpenCL-capable graphics card driver).
Usage
-
Run rundal.xml with OpenCL Code Generator back-end selected as code generator. For example:
$ ant -f rundal.xml -Dbenchmark=ProducerConsumer -Dgenerator=opencl -Dplatform=inteli7_amd_opencl -Dmapping=mappingOpenCL
More Information
- A summary of the basic concepts used by the back-end can be found in ESTIMedia 2013.
- Detailed information about the runtime-system can be found in the master thesis of Tobias Scherer.
- Detailed information about the program synthesis step can be found in the semester thesis of Matthias Baer.