Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: GOTO BLAS and multiple threads
Date: Fri, 6 Feb 2009 19:09:01 +0000 (UTC)
Organization: UoFC
Lines: 26
Message-ID: <gmi1sd$df3$1@fred.mathworks.com>
References: <g7seu6$4du$1@news2.rz.uni-karlsruhe.de> <g7udqa$59s$1@news2.rz.uni-karlsruhe.de>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1233947341 13795 172.30.248.38 (6 Feb 2009 19:09:01 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Fri, 6 Feb 2009 19:09:01 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1662491
Xref: news.mathworks.com comp.soft-sys.matlab:516664


But how to compile go to blas with matlab

Arne Schneck <arne.schneck@math.uni-karlsruhe.de> wrote in message <g7udqa$59s$1@news2.rz.uni-karlsruhe.de>...
> Arne Schneck wrote:
> > I've been trying to use GOTO BLAS instead of the BLAS implementation that
> > comes with Matlab. The problem is that when I compile a C file (with mex)
> > that uses one of the BLAS routines from the GOTO library (dsyrk in my
> > case), it only uses 1 thread.
> 
> Okay, I kind of solved the problem, but something is still messed up. In
> order to uses Goto's BLAS, I just set the BLAS_VERSION environment variable
> to the Goto BLAS library. This makes Matlab commands like A*A' call the
> BLAS subroutine from Goto's library instead of the ACML library. And it
> apparently uses (at least) 8 threads. So that solves the issue for me.
> 
> But: When I link C MEX files against libgoto, the resulting MEX file shows
> pretty random behavior which completely baffles me. In one Matlab session
> it uses 8 threads (don't know for sure, but at least it's fast), then I
> restart Matlab and it uses only 1 thread. Although nothing was changed. On
> each restart of Matlab it randomly seems to choose whether to use 1 or 8
> threads!
> 
> Anyone have any idea what's going on here?
> 
> Arne
>