Stream and Kernel Intermediate Representation (SKIR) with LLVM
Project Overview
The SKIR project is investigating the extension of virtual machine representations with parallel programming primitives (instructions) to support the efficient creation, representation and optimization of programs targeting parallel and heterogeneous hardware. Specifically, we are extending the LLVM language and compiler with stream processing operations and developing a runtime software layer to manage the execution of the resulting programs.
The Stream and Kernel Intermediate Representation (SKIR) is a small set of LLVM intrinsics for expressing parallel computation as a graph of sequential processes (kernels) communicating over abstract data channels (streams). At runtime, programs use the SKIR intrinsics to identify functions to use as kernels, to connect kernels together using streams, and to execute resulting program graphs. Formally, the stream parallelism expressed by SKIR programs can be viewed as a generalization of Kahn process networks. More practically, we can use SKIR as a compilation target for high level languages and frameworks containing this style of program decomposition and communication.
We have used SKIR to implement a compiler for the StreamIt language, to create a C++ user library for stream/data/pipeline parallel programming, and to enable parallel programming for JavaScript applications. SKIR is implemented on top of the LLVM JIT compiler and a work stealing task scheduler. We use runtime compilation because of the runtime construction of program graphs, so that we can support dynamic optimization, and so that we can perform dynamic recompilation for heterogeneous targets. In this talk I will describe the SKIR intrinsics and programming model, and briefly describe high level language support that has been implemented for SKIR. I will present the compilation and optimization techniques used to transform the sequential LLVM+SKIR input code into concurrent code which can be executed in parallel using dynamic scheduling techniques. I will also describe how we can use LLVM JIT compilation to dynamically increase or decrease the amount of parallelism in a SKIR program depending on runtime hardware and application characteristics. Finally, I will describe how we can further accelerate SKIR program kernels using JIT compilation, our OpenCL backend, and GPUs.
Project web site: http://systems.cs.colorado.edu/wiki/SKIR
Slides: http://llvm.org/devmtg/2011-11/Fifield_SKIR.pdf
Category: Computer Science
-
http://www.streamcomputing.eu Vincent
-
Anonymous
-






