Research on Speedup Ratio Based on Reduction and Critical
Open Access
- 18 November 2023
- conference paper
- Published by Association for Computing Machinery (ACM)
- p. 319-325
Abstract
Reduction and critical are two methods to synchronize access to shared variables in parallel regions in OpenMP, which have a certain impact on the performance of many parallel computations. Therefore, the parallel speedup ratio of reduction and critical has a certain research value. In this paper, three common mathematical problems such as solving calculus equation, determinant expansion and matrix multiplication are taken as examples to write corresponding parallel programs. The parallel parts of the program are executed by using reduction and critical instructions respectively, and the speedup ratios of the above two instructions in program execution are emphatically tested under different calculation scales and different thread numbers. The results show that the performance of reduction instruction is better than that of critical instruction when a shared variable is required to be specified. When the task scale is small, critical instruction can improve the performance of the program, but with the increase of the task scale, critical instruction will become the bottleneck of the program and affect the scalability of the program. In OpenMP programming, programmers need to choose different instructions flexibly according to the nature and requirements of tasks in order to obtain better performance and efficiency.Keywords
This publication has 1 reference indexed in Scilit:
- Parallel computation of a dam-break flow model using OpenMP on a multi-core computerJournal of Hydrology, 2014