Hi, it seems the version of ATLAS in Fedora 20 is not thread-safe. Namely, calling ATLAS functions within OpenMP sections of my code produces insane results, while the same code runs properly in sequential mode. I also have no problems using the OpenMP version of OpenBLAS. Looking at the library $ ldd /usr/lib64/atlas/libatlas.so linux-vdso.so.1 => (0x00007fffcb3fc000) libc.so.6 => /lib64/libc.so.6 (0x0000003936e00000) libpthread.so.0 => /lib64/libpthread.so.0 (0x0000003937600000) libm.so.6 => /lib64/libm.so.6 (0x0000003937a00000) /lib64/ld-linux-x86-64.so.2 (0x0000003936a00000) it would seem that it's threading by itself, which might have to do with the problem.
Hi, There are libraries: /usr/lib64/atlas/libcblas.so /usr/lib64/atlas/libf77blas.so They provide single threaded interface. Then other libraries: /usr/lib64/atlas/libptcblas.so /usr/lib64/atlas/libptf77blas.so provide multi-threaded interface. /usr/lib64/atlas/libatlas.so is the backend for all of them. Yes, it is linked against pthreads and it does or does not it's own threading as requested. Or at least such is the idea, I do not know if it has bugs or not. Threading itself has known bugs and it will be probably rewritten substantially in the future. If you use libatlas.so directly, which functions and how?
I've noticed that dsyev fails to get accurate eigenvectors when called in parallel sections, even on Fedora 21.
Actually, I've noticed the same issue with OpenBLAS. This was due to LAPACK not being built thread safe. I've fixed the issue in LAPACK, and will do rebuilds of OpenBLAS and ATLAS which might fix this issue as well.
Well, actually, since ATLAS doesn't use the lapack package at all, this problem won't be resolved. You should use the object files from the lapack{,64}-static package in ATLAS. Failing that, adding -frecursive to the LAPACK compile flags should fix the thread safety.
The problem with ATLAS is indeed in LAPACK, as well. Rebuilding ATLAS with a LAPACK built with -frecursive fixes the thread safety problems I've seen. The fix is in atlas-3.8.4-14.fc20.x86_64.rpm, but F21 and rawhide need addressing as well. If you build against system LAPACK as the ATLAS used to do (and as OpenBLAS still does), this problem will be solved as well.
I fixed the issue in Fedora 20, but Fedora 21 still needs fixing.
atlas-3.10.1-17.fc21 has been submitted as an update for Fedora 21. https://admin.fedoraproject.org/updates/atlas-3.10.1-17.fc21
Package atlas-3.10.1-17.fc21: * should fix your issue, * was pushed to the Fedora 21 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing atlas-3.10.1-17.fc21' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2015-1591/atlas-3.10.1-17.fc21 then log in and leave karma (feedback).
atlas-3.10.1-18.fc21 has been submitted as an update for Fedora 21. https://admin.fedoraproject.org/updates/atlas-3.10.1-18.fc21
atlas-3.10.1-18.fc21 has been pushed to the Fedora 21 stable repository. If problems still persist, please make note of it in this bug report.