AnyDSL: a partial evaluation framework for programming high-performance libraries
Open Access
- 24 October 2018
- journal article
- research article
- Published by Association for Computing Machinery (ACM) in Proceedings of the ACM on Programming Languages
- Vol. 2 (OOPSLA) , 1-30
Abstract
This paper advocates programming high-performance code using partial evaluation. We present a clean-slate programming system with a simple, annotation-based, online partial evaluator that operates on a CPS-style intermediate representation. Our system exposes code generation for accelerators (vectorization/parallelization for CPUs and GPUs) via compiler-known higher-order functions that can be subjected to partial evaluation. This way, generic implementations can be instantiated with target-specific code at compile time. In our experimental evaluation we present three extensive case studies from image processing, ray tracing, and genome sequence alignment. We demonstrate that using partial evaluation, we obtain high-performance implementations for CPUs and GPUs from one language and one code base in a generic way. The performance of our codes is mostly within 10%, often closer to the performance of multi man-year, industry-grade, manually-optimized expert codes that are considered to be among the top contenders in their fields.Keywords
Funding Information
- Bundesministerium für Forschung, Technologie und Raumfahrt (Metacca & ProThOS)
- Intel Visual Computing Institute, Universität des Saarlandes
- Cluster of Excellence on Multimodal Computing and Interaction, Saarland University
This publication has 59 references indexed in Scilit:
- GROMACS 4.5: a high-throughput and highly parallel open source molecular simulation toolkitBioinformatics, 2013
- A self‐applicable online partial evaluator for recursive flowchart languagesSoftware: Practice and Experience, 2011
- OptiXACM Transactions on Graphics, 2010
- Efficient analyses for realistic off-line partial evaluationJournal of Functional Programming, 2008
- Scalable Parallel Programming with CUDAQueue, 2008
- SeqAn An efficient, generic C++ library for sequence analysisBMC Bioinformatics, 2008
- Automatic program specialization for JavaACM Transactions on Programming Languages and Systems, 2003
- Binding-time analysis for Standard MLHigher-Order and Symbolic Computation, 1995
- Mix: A self-applicable partial evaluator for experiments in compiler generationHigher-Order and Symbolic Computation, 1989
- A linear space algorithm for computing maximal common subsequencesCommunications of the ACM, 1975