[R-sig-Debian] R and multi cpu ATLAS

Paul Johnson pauljohn32 at gmail.com
Fri Jun 4 23:16:44 CEST 2010

On Thu, Jun 3, 2010 at 12:21 PM, Andrew Piskorski <atp at piskorski.com> wrote:
> On Thu, Jun 03, 2010 at 11:31:02AM -0500, Paul Johnson wrote:
>> I wonder, though, if you can point me at some documentation that says
>> how it is *supposed* to work with R and Atlas. From what I can tall, R
> I don't think R is immediately relevant to the question here.  The
> Atlas docs are pretty clear that Atlas will run multi-threaded, using
> up to N cores, IFF it is compiled to do so.  The limit N is set at
> compile time:
>  http://math-atlas.sourceforge.net/faq.html#tnum
> On my dual-core laptop running Ubuntu 9.04, the libatlas-test programs
> also run using only one core.  So, I doubt this has anything to do
> with R, most likely the Ubuntu Atlas packages are built to use one
> thread only.  To figure it out, you should look into how and why the
> Ubuntu Atlas packages are compiled exactly, perhaps comparing to the
> stock Atlas build instructions.

Please run this and see if the last command causes the use of more
than one core. With GotoBLAS2 or the Intel MKL as BLAS, it does

mm <- matrix(rnorm(10^7), ncol = 10^3)


system.time(mmm <- mm %*% t(mm))

> --
> Andrew Piskorski <atp at piskorski.com>
> http://www.piskorski.com/

Paul E. Johnson
Professor, Political Science
1541 Lilac Lane, Room 504
University of Kansas

More information about the R-SIG-Debian mailing list