3 ms·
GFortran maintainer here. Please don't judge GFortran by the speed of the MATMUL intrinsic. The matmul implementation is really a bare-bones unoptimized version
by jabl 11y ago
GFortran maintainer here. Please don't judge GFortran by the speed of the MATMUL intrinsic. The matmul implementation is really a bare-bones unoptimized version. If you want performance use the -fexternal-blas option and link in a tuned BLAS library such as MKL or OpenBLAS. The exception is if you have very small fixed-size matrices, then the code is inlined and should be faster than BLAS.
- squidfood 11y agoThanks! I should mention that these tests were for a specific (highly tuned for the specific job) production HPC machine, so I don't know how this compares to a more generic setup - unfair of me to generalize the results to every matrix multiplication. We developed off the production machine in GFortran, and it worked very very well for us - didn't do timing tests there, but anecdotally, in development the difference was unnoticeable.
- gh02t 11y agoOh cool! Thanks for your time maintaining Gfortran. I know I said Intel has a stranglehold, but personally I prefer using Gfortran where I can as I prefer open source. So thanks!