The Impact of Compilation Flags and Choosing Single- or Double-Precision Variables in Linear Systems Solvers

Autores

DOI:

https://doi.org/10.5540/tcam.2023.024.02.00319

Palavras-chave:

Linear systems, Compiler flags, Optimization, Variable precision

Resumo

This paper intends to show the impact of compiler optimization flags and the variable's precision on direct methods to solve linear systems. The chosen six methods are simple direct methods, so our work could be a study for new researchers in this field. The methods are LU decomposition, LDU decomposition, Gaussian Elimination, Gauss-Jordan Elimination, Cholesky decomposition, and QR decomposition using the Gram-Schmidt orthogonalization process. Our study showed a huge difference in time between single- and double-precision in all methods, but the error encountered in the single-precision was not so high. Also, the best flags to these methods were the `-O3' and the `-Ofast' ones.

Biografia do Autor

R. C. Brum, Universidade do Estado do Rio de Janeiro

Programa de Pós-Graduação em Ciências Computacionais, IME

M. C. S. de Castro, Universidade do Estado do Rio de Janeiro

Programa de Pós-Graduação em Ciências Computacionais, IME

C. O. Faria, Universidade do Estado do Rio de Janeiro

Programa de Pós-Graduação em Ciências Computacionais, IME

Referências

G. H. Golub and C. F. Van Loan, Matrix Computations (3rd Ed.). Baltimore, MD, USA: Johns Hopkins University Press, 1996.

J. W. Demmel, Applied Numerical Linear Algebra. SIAM, Jan. 1997.

D. S. Watkins, Fundamentals of matrix computations. Pure and applied mathematics, New York: Wiley-Interscience, 2nd ed ed., 2002.

M. C. C. Cunha, Métodos numéricos. Editora da UNICAMP, 2003.

D. A. Patterson and J. L. Hennessy, Organização e projeto de computadores: interface hardware/software. Elsevier Brasil, 2014.

A. F. G. Ascencio and E. A. V. d. Campos, Fundamentos da programação de computadores: algoritmos, Pascal, C/C++ e Java. São Paulo: Pearson Prentice Hall, 2008.

T. Botor and H. Habiballa, “Compiler optimization for scientific computation in C/C++,” (Thessaloniki, Greece), p. 030004, 2018.

K. Hoste and L. Eeckhout, “Cole: compiler optimization level exploration,” in Proceedings of the 6th annual IEEE/ACM international symposium on Code generation and optimization, pp. 165–174, ACM, 2008.

https://gcc.gnu.org/onlinedocs/gcc-5.4.0/gcc/, 2016 (accessed December 6, 2018).

https://gcc.gnu.org/onlinedocs/gcc-7.1.0/gcc/, 2017 (accessed December 6, 2018).

M. A. G. Ruggiero and V. L. d. R. Lopes, Cálculo numérico: aspectos teóricos e computacionais. Makron Books do Brasil, 1997.

Downloads

Publicado

2023-05-24

Como Citar

Brum, R. C., de Castro, M. C. S., & Faria, C. O. (2023). The Impact of Compilation Flags and Choosing Single- or Double-Precision Variables in Linear Systems Solvers. Trends in Computational and Applied Mathematics, 24(2), 319–335. https://doi.org/10.5540/tcam.2023.024.02.00319

Edição

Seção

Artigo Original