Abstract
OpenMP, a widely adopted standard for shared memory parallel programming, is known for its simplicity and portability, making it accessible to programmers across various domains, not just HPC experts. This study aims at providing an overview of the current practice of OpenMP usage in open source projects. We focus our study on the considerations necessary for efficient OpenMP usage, as parallelizing an application with OpenMP comes with a certain overhead necessary for thread creation and management.
For this purpose, we developed a binary analysis tool that automatically estimates the complexity of a parallel region allowing a comparison with the complexity of thread creation and management overhead in bluk. We applied this tool on a large set of 537 open source applications. Specifically, we want to answer the question: “To what extent is the usage of OpenMP in general following known good practices from the HPC community?" In particular, we find that \(45\%\) of projects contain at least one example of a rather simple parallel region. In these cases, it is questionable whether parallelization is worth the overhead necessary for thread creation and management. We also observe from the codes analysed that the style of using OpenMP apparently did not change over the last decade.
Our analysis tool is available on GitHub: https://github.com/tudasc/openmp-analysis.
T. Jammer and C. Iwainsky—Both authors contributed equally to this research.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
We do not weigh all instructions due to the computational cost of the full control flow graph analysis necessary.
References
Amdahl, G.M.: Validity of the single processor approach to achieving large scale computing capabilities. In: Proceedings of the April 18–20, 1967, Spring Joint Computer Conference, pp. 483–485, AFIPS 1967 (Spring), Association for Computing Machinery, New York, NY, USA (1967). ISBN 9781450378956, https://doi.org/10.1145/1465482.1465560
Iwainsky, C., et al.: How many threads will be too many? On the scalability of OpenMP implementations. In: Träff, J.L., Hunold, S., Versaci, F. (eds.) Euro-Par 2015. LNCS, vol. 9233, pp. 451–463. Springer, Heidelberg (2015). https://doi.org/10.1007/978-3-662-48096-0_35
Jammer, T., Iwainsky, C., Bischof, C.: A comparison of the scalability of OpenMP implementations. In: Malawski, M., Rzadca, K. (eds.) Euro-Par 2020. LNCS, vol. 12247, pp. 83–97. Springer, Cham (2020). https://doi.org/10.1007/978-3-030-57675-2_6
Kadosh, T., Hasabnis, N., Mattson, T., Pinter, Y., Oren, G.: Quantifying OpenMP: statistical insights into usage and adoption. In: 2023 IEEE High Performance Extreme Computing Conference (HPEC), pp. 1–7. IEEE (2023)
Machiry, A., et al.: BOOMERANG: exploiting the semantic gap in trusted execution environments. In: Proceedings of the 2017 Network and Distributed System Security Symposium (2017)
Parvez, M.R.: Combining static analysis and targeted symbolic execution for scalable bug-finding in application binaries (2016)
Pewny, J., Garmany, B., Gawlik, R., Rossow, C., Holz, T.: Cross-architecture bug search in binary executables. In: 2015 IEEE Symposium on Security and Privacy (SP), pp. 709–724. IEEE (2015)
Shoshitaishvili, Y., Wang, R., Hauser, C., Kruegel, C., Vigna, G.: Firmalice - automatic detection of authentication bypass vulnerabilities in binary firmware. In: Proceedings of the 2015 Network and Distributed System Security Symposium (2015)
Shoshitaishvili, Y., et al.: SoK: (State of) the art of war: offensive techniques in binary analysis. In: IEEE Symposium on Security and Privacy (2016)
Squar, J., Schroeter, N., Fuchs, A., Kuhn, M., Ludwig, T.: Content queries and in-depth analysis on version-controlled software. Proc. Comput. Sci. 207, 1261–1270 (2022)
Acknowledgements
We thank René Sitt from the University of Marburg for invaluable assistance in building the Open source GitHub repositories, which greatly enhanced the scope and impact of this project.
This work was supported by the Hessian Ministry for Higher Education, Research and the Arts through the Hessian Competence Center for High-Performance Computing and by the Federal Ministry of Education and Research (BMBF) and the states of Hesse as part of the NHR program. Measurement for this work were conducted on the Lichtenberg high performance computer of TU Darmstadt.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2024 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Jammer, T., Iwainsky, C., Bischof, C. (2024). Survey of OpenMP Practice in General Open Source Software. In: Espinosa, A., Klemm, M., de Supinski, B.R., Cytowski, M., Klinkenberg, J. (eds) Advancing OpenMP for Future Accelerators. IWOMP 2024. Lecture Notes in Computer Science, vol 15195. Springer, Cham. https://doi.org/10.1007/978-3-031-72567-8_7
Download citation
DOI: https://doi.org/10.1007/978-3-031-72567-8_7
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-72566-1
Online ISBN: 978-3-031-72567-8
eBook Packages: Computer ScienceComputer Science (R0)