Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 528974 - [science overlay] sci-libs/openblas-0.2.12 - openmp is not used because "USE_THREAD=0 USE_OPENMP=1" are both set during the configure phase
Summary: [science overlay] sci-libs/openblas-0.2.12 - openmp is not used because "USE_...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Science Related Packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-11 21:23 UTC by Libor Bukata
Modified: 2015-04-02 09:58 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (file_528974.txt,7.01 KB, text/plain)
2014-11-11 21:25 UTC, Libor Bukata
Details
Modified ebuild file which solves the openmp issue. (openblas-0.2.12-r1.ebuild,7.15 KB, text/plain)
2014-11-11 21:29 UTC, Libor Bukata
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Libor Bukata 2014-11-11 21:23:48 UTC
Current version of openblas is not multi-threaded due to a bug in an ebuild file, where "USE_THREAD=0 USE_OPENMP=1" are set both during the configuration phase. If threads are disabled the openmp will not be used as it necessary requires pthread library. 

Reproducible: Always

Steps to Reproduce:
1. compile openblas with openmp flag enabled
2. ldd /usr/lib64/libopenblas_openmp.so
-> it is not linked against libgomp.so



Actual Results:  
Using e.g. Octave for heavy computations it can be perceived that multi-threading is not in use.

Expected Results:  
Parallel version of openblas compiled correctly.

I have modified the ebuild (see the attachment) to set only USE_OPENMP=1 if openmp flag is enabled. Furthemore, the flag "threads" was removed since it says whether threads should be used or not (USE_OPENMP=1 -> USE_THREADS=1 and vice versa). Please correct me if I am wrong.
Comment 1 Libor Bukata 2014-11-11 21:25:05 UTC
Created attachment 389130 [details]
emerge --info
Comment 2 Libor Bukata 2014-11-11 21:29:44 UTC
Created attachment 389132 [details]
Modified ebuild file which solves the openmp issue.

I will be grateful for any remarks regarding ebuild modification.
Comment 3 François Bissey 2015-03-29 20:27:18 UTC
Well it now breaks the build:
make -j12 -j1 libs shared INTERFACE64=1 USE_THREAD=0 USE_OPENMP=1 LIBNAMESUFFIX=int64_openmp 
Makefile.system:370: *** OpenBLAS: Cannot set both USE_OPENMP=1 and USE_THREAD=0. The USE_THREAD=0 is only for building single thread version..  Stop.

Historically you had to use either USE_OPENMP or USE_THREAD but not both at the same time, the meaning of those must have changed.
Comment 4 Marius Brehler 2015-04-02 09:58:26 UTC
+  02 Apr 2015; Marius Brehler <marbre@linux.sungazer.de> openblas-9999.ebuild:
+  Fix Bug 528974
+

Version 0.2.12 and 0.2.14 are symlinks that point to 9999. Should be fixed.