Pure functions in C: A small keyword for automatic parallelization
conference contributionposted on 06.02.2018, 11:49 by Tim Suss, Lars Nagel, Marc-Andre Vef, Andre Brinkmann, Dustin Feld, Thomas Soddemann
© 2017 IEEE. The need for parallel task execution has been steadily growing in recent years since manufacturers mainly improve processor performance by scaling the number of installed cores instead of the frequency of processors. To make use of this potential, an essential technique to increase the parallelism of a program is to parallelize loops. However, a main restriction of available tools for automatic loop parallelization is that the loops often have to be 'polyhedral' and that it is, e.g., not allowed to call functions from within the loops.In this paper, we present a seemingly simple extension to the C programming language which marks functions without side-effects. These functions can then basically be ignored when checking the parallelization opportunities for polyhedral loops. We extended the GCC compiler toolchain accordingly and evaluated several real-world applications showing that our extension helps to identify additional parallelization chances and, thus, to significantly enhance the performance of applications.
This work was supported by the German Ministry for Education and Research under grant 01|H13004A (FAST).
- Computer Science