On Thu, 23 Jan 2020, Marcin Błażejowski wrote:
On 23.01.2020 18:23, Allin Cottrell wrote:
> On Thu, 23 Jan 2020, Marcin Błażejowski wrote:
>
>> That is something which bothers me: I have OpenBLAS 0.3.7+ds-7 taken
>> from Debian repos (libopenblas-base:amd64 +
>> libopenblas-openmp-dev:amd64) and gretl links (after a long alternatives
>> chain) against '/usr/lib/x86_64-linux-gnu/openblas-openmp/libblas.so.3'
>> (and in case of LAPACK against
>> '/usr/lib/x86_64-linux-gnu/openblas-openmp/liblapack.so.3'). Looks good:
>> OpenBLAS witn OpenMP. But 'eval $sysinfo' produces following results:
>>
>> bundle anonymous:
>> ncores = 4
>> mpi = 1
>> omp = 1
>> hostname = "marcin-note"
>> os = "linux"
>> omp_num_threads = 4
>> mpimax = 8
>> blas = "netlib"
>> nproc = 8
>> wordlen = 64
>
> Marcin, if the OS is not delivering the desired linkage via its
> "alternatives" mechanism you can force the issue by defining
> LAPACK_LIBS at gretl configure time. For example, on Fedora I'm doing
Allin,
but:
1. ldd /usr/local/bin/gretlcli | grep blas produces: libblas.so.3 =>
/usr/lib/x86_64-linux-gnu/libblas.so.3
2. ll /usr/lib/x86_64-linux-gnu/libblas.so.3 gives:
/usr/lib/x86_64-linux-gnu/libblas.so.3 ->
/etc/alternatives/libblas.so.3-x86_64-linux-gnu
3. ll /etc/alternatives/libblas.so.3-x86_64-linux-gnu gives:
/etc/alternatives/libblas.so.3-x86_64-linux-gnu ->
/usr/lib/x86_64-linux-gnu/openblas-openmp/libblas.so.3
So, it looks like linking against OpenBLAS, am I right?
Probably ;-). I guess it's just that gretl can't detect the fact
that you're actually linked against OpenBLAS, amidst all this
trickery!
Unfortunately (so far as I'm aware) there's no symbol defined in a
BLAS library and accessible by the caller that actually tells us
what implementation we're looking at. Gretl therefore relies on a
heuristic (using ldd) which, in this case, is not telling us
anything useful: we just get "libblas.so.3", which we take to be
netlib.
So, while it shouldn't make any difference to performance, if you
want gretl's $sysinfo to report the correct BLAS implementation you
may have to use the LAPACK_LIBS variable.
Allin