The codes for quantum mechanical calculations make heavy use of linear algebra, and it seems most of them delegate this task to time-tested and highly optimized libraries, instead of trying to deploy their own. There is a plethora of options. For example, when we install Gamess-US in Ubuntu GNU/Linux, several options are listed, both proprietary and free / open source software:
In the past I used ATLAS, and then MKL, as we are nudged towards it by the (very fast) qualifier given in the install screen. But then I was doing some research on it, and found this information on its wikipedia page:
Intel MKL and other programs generated by the Intel C++ Compiler improve performance with a technique called function multi-versioning: a function is compiled or written for many of the x86 instruction set extensions, and at run-time a "master function" uses the CPUID instruction to select a version most appropriate for the current CPU. However, as long as the master function detects a non-Intel CPU, it almost always chooses the most basic (and slowest) function to use, regardless of what instruction sets the CPU claims to support. This has netted the system a nickname of "cripple AMD" routine since 2009.
This got me a bit worried, as I'm trying to do a Gamess-US install in a machine with a Ryzen processor, and so I'm afraid I will get a crippled install if I use intel MKL. Given the number of remaining choices, without a clear idea of relative performance between them, I got some analysis paralysis. The obvious alternative would be one of AMD, but in absence of a substantial speed advantage, I could as well use a open source one, as I try to favor free software whenever I can.
If someone more experienced could give some advice on this problem, I would be grateful. How does the several linear algebra libraries compare to each other, on the workloads typical of materials modeling? Is there a big difference from one to other, or they are all optimized to such degree that doesn't matter much which one is used. Is there one with good overall performance over a variety of hardware, not biased against alternative hardware like the MKL seems to be?