PEPPHER Composition Tool
The PEPPHER Composition Tool is a research prototype developed at
Linköping University (Sweden),
as part of the EU FP7 project PEPPHER (2010-2012).
The main functionality of the current version of the composition tool
is to compose C/C++ based applications for heterogeneous multi-/manycore systems
from application-level building blocks (components)
that are written and annotated using the
PEPPHER component model.
Currently, the composition tool supports component implementations written in sequential C/C++, OpenMP, CUDA and OpenCL, and for
uses the PEPPHER runtime system (which is built upon open-source StarPU runtime system) to do
the composition at runtime (i.e. dynamic composition). Besides dynamic composition, it supports user-guided static composition.
The PEPPHER Component model
The PEPPHER component model is a comprehensive framework for annotating software components for heterogeneous multicore systems that are written in various programming models for CPUs and GPUs with rich metadata to expose their variation points and tuning options to an external software composition tool.
Instead of hardcoding such performance optimizations for a specific platform configuration in the application code, a composition tool will generate code for the application from its components and their implementation variants such that
the composed code automatically adapts its runtime behavior (e.g., selection of
implementation variants, scheduling, resource allocation, ...)
for a given platform and for a given runtime context (which might
comprise performance-relevant properties such as problem sizes or
current load of processing units), in order to optimize program execution.
This supports both code portability and performance portability.
The PEPPHER component model is generic in its design; however, it is currently realized in C/C++ so we will here discuss it with respect to C/C++.
A PEPPHER component consists of an interface and one or more implementations of that interface. Both interface and implementations are complemented with extra information (called "meta-data") in the form of XML descriptors. In this sense the PEPPHER component model is non-intrusive, as it require very little direct modification in the user code.
PEPPHER component interface
In C/C++, a PEPPHER interface is represented by a C/C++ function declaration. For example, following is an example of sorting interface:
void sort(float *arr, int size);
Besides function declaration, an interface has an assosiated XML descriptor which models extra information about the interface. This includes information about:
PEPPHER components are stateless which means that all input and output operands of a component interface are modelled by its parameter list and return type, i.e., no global variables shall be accessed inside a PEPPHER component.
- Access patterns of parameters (i.e. is it read, written or both inside the component)
- Relationship between parameters (e.g. in above sorting interface, "size" parameter defines total number of parameters of "arr" parameter)
- Performance model (if any) assosiated with the component...
PEPPHER component implementations
A PEPPHER implementation implements the functionality promised by a PEPPHER interface while keeping the same calling interface (return-type, parameter-types).
For example, for sorting interface, we can have the following implementations:
void qs_cpu_imp(float *arr, int size)
void ms_cpu_imp(float *arr, int size)
void qs_gpu_imp(float *arr, int size)
void bs_gpu_imp(float *arr, int size)
Like component interfaces, each PEPPHER component implementation has an associated XML descriptor describing this implementation's meta-data.
The descriptor specifies:
- The interface that the implementation implements.
- The programming language of the implementation
(e.g. C/C++, OpenMP, CUDA, OpenCL)
- Information about specific library usages.
- Information about compilation, if it requires some specific compilation command (such as specific include or link directives for libraries that it uses internally).
Papers and Posters
- Usman Dastgeer, Lu Li, Christoph Kessler:
The PEPPHER Composition Tool: Performance-Aware Dynamic Composition of Applications for GPU-based Systems.
In Proc. 2012 Int. Workshop on Multi-Core Computing Systems (MuCoCoS 2012), Nov. 16, 2012, Salt Lake City, Utah, USA, in conjunction with the Supercomputing Conference (SC12). Author-version (pdf)
- Lu Li, Usman Dastgeer, Christoph Kessler:
Adaptive off-line tuning for optimized composition of components for heterogeneous many-core systems.
Accepted for the Seventh International Workshop on Automatic Performance Tuning (iWAPT-2012), 17 July 2012, Kobe, Japan. To appear in: Proc. VECPAR-2012 Conference, Kobe, Japan, July 2012. Author-version (pdf)
- PEPPHER Composition Tool: Performance-Aware Dynamic Composition of Applications for GPU-based Systems. Poster presented at ACACES-2012 and HiPEAC-2013. Poster pdf
An online manual
The prototype is not released publicly yet. If you are interested, please let us know via e-mail.
The composition tool is being further developed; current work focuses on adding a more complex form of static composition using off-line tuning.
We have ported several applications from the
RODINIA benchmark suite,
an ODE Solver, a Lightfield Photography (image refocusing) application
and several small applications/kernels (SpMxV, SGEMM, SGEMV etc.).
More details about evaluation can be found in information sources.
Contact: Usman Dastgeer, Lu Li, Prof. Christoph Kessler. For contact, please e-mail to "<firstname> DOT <lastname> AT liu DOT se".
This work was funded by EU FP7 project PEPPHER during 2010-2012 period.
Its current development is partly funded by SeRC-OpCoReS and Vetenskapsrådet.