Publication Type
Conference Proceeding Article
Version
publishedVersion
Publication Date
10-2015
Abstract
Using GPUs as general-purpose processors has revolutionized parallel computing by offering, for a large and growing set of algorithms, massive data-parallelization on desktop machines. An obstacle to widespread adoption, however, is the difficulty of programming them and the low-level control of the hardware required to achieve good performance. This paper suggests a programming library, SafeGPU, that aims at striking a balance between programmer productivity and performance, by making GPU data-parallel operations accessible from within a classical object-oriented programming language. The solution is integrated with the design-by-contract approach, which increases confidence in functional program correctness by embedding executable program specifications into the program text. We show that our library leads to modular and maintainable code that is accessible to GPGPU non-experts, while providing performance that is comparable with hand-written CUDA code. Furthermore, runtime contract checking turns out to be feasible, as the contracts can be executed on the GPU.
Keywords
GPGPU, parallel computing, runtime code generation, programming, object-orientation, design-by-contract, program correctness
Discipline
Programming Languages and Compilers | Software Engineering
Research Areas
Software and Cyber-Physical Systems
Publication
Proceedings of the 2015 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, Pittsburgh PA, USA, October 26-27
Volume
51
Issue
3
First Page
75
Last Page
84
Identifier
10.1145/2814204.2814216
Publisher
ACM
City or Country
Pittsburgh, PA, USA
Citation
KOLESNICHENKO, Alexey; POSKITT, Christopher M.; NANZ, Sebastian; and MEYER, Bertrand.
Contract-based general-purpose GPU programming. (2015). Proceedings of the 2015 ACM SIGPLAN International Conference on Generative Programming: Concepts and Experiences, Pittsburgh PA, USA, October 26-27. 51, (3), 75-84.
Available at: https://ink.library.smu.edu.sg/sis_research/4910
Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-No Derivative Works 4.0 International License.
Additional URL
https://doi.org/10.1145/2814204.2814216