Building libflame and blis relation.

103 views
Skip to first unread message

Erling D. Andersen

unread,
Nov 9, 2018, 3:49:13 AM11/9/18
to libflame-discuss
Hi

1) libflame vs blis:

I am confused about the relation between libflame and blis. Currently I use blis but wants to use potrf from libflame and maybe other functions. So should I link with both libraries or does libflame contain blis?

2) Building libflame:

I would like to build libflame single threaded but threadsafe e.g. I might want to call potrf from multiple threads but potrf should always run single threaded.

For blis I achieve threadsafe but single threaded usage using

./configure --enable-threading=pthreads ......

and

bli_thread_set_num_threads( 1 );

How do I do that for libflame?

Regards

Erling

Field G. Van Zee

unread,
Nov 9, 2018, 12:54:27 PM11/9/18
to libflame...@googlegroups.com
Erling,

Sorry, I am just now seeing this message.

Just for the record, libflame provides LAPACK-level functionality, while
BLIS provides BLAS-level functionality. There is no meaningful overlap
between the two (yet). (Someday, I may begin to re-implement some of the
important libflame functions within BLIS.) However, as I note in my
previous message, BLIS provides much more than just BLAS. The full APIs
are documented on our github website.

As for libflame's thread-safety, I can't be certain at this time,
unfortunately. I haven't done a top-to-bottom audit of libflame lately
to ensure its thread safety status, so I wouldn't be surprised if there
is some work left to be done there. But I can say that BLIS is
thread-safe under normal working conditions.

Field

Erling D. Andersen

unread,
Nov 14, 2018, 7:16:05 AM11/14/18
to libflame-discuss
Thanks for the feedback.

We need something that runs single threaded but is thread safe e.g. calling gemm or potrf from multiple threads. The pthreads mode of blis seems to work for that purpose.

At this point in time I do not dare use libflame given your comments since we are commercial vendor and is responsible towards our customers.

Keep up the good work.

Field G. Van Zee

unread,
Nov 14, 2018, 1:53:43 PM11/14/18
to libflame...@googlegroups.com
Erling,

I understand your caution vis-a-vis thread safety. Interestingly, even
netlib LAPACK is not thread-safe for some routines, mostly due to
limitations in the BLAS interface--limitations that BLIS fixes--though
that is another story altogether.

Thanks for your interest in BLIS (and libflame). Please keep in touch!

Field

Erling D. Andersen

unread,
Nov 15, 2018, 4:11:25 AM11/15/18
to libflame-discuss
When do some task it takes 168s with MKL and 107s with BLIS both run an AMD CPU. Very nice. :-).
Reply all
Reply to author
Forward
0 new messages