From simon.urbanek at r-project.org  Mon Nov 22 22:56:37 2010
From: simon.urbanek at r-project.org (Simon Urbanek)
Date: Mon, 22 Nov 2010 16:56:37 -0500
Subject: [Rd] R-.12.0 atlas lapack
In-Reply-To: <201011221759.13973.lux-integ@btconnect.com>
References: <201011202235.02520.lux-integ@btconnect.com>
	<201011221759.13973.lux-integ@btconnect.com>
Message-ID: <A2F4A7D7-65A9-4316-AFC6-2B3F3B9C486E@r-project.org>


On Nov 22, 2010, at 12:59 PM, luxInteg wrote:

> On Saturday 20 November 2010 22:35:02 luxInteg wrote:
>> Greetings,
>> 
>> I last  built R-2.11.1  a few months ago.  The computer was equipped with
>> these:-
>> 
>> ---cpu amd64 2 cores
>> ---o/s cblfs 64-bit only linux kernel-2.6.32 gcc-4.4.2 jdk(1.5)-6U20?
>> ---bls atlas3.9.26  lapacck-3.2.1
>> 
>> I obtained   an installed directory of ~58Mbytes  and in the ~/lib
>> directory was  libR.so (~7.8Mbytes in size) as well as libRblas.so and
>> libRlapack.so (~2.9Mbytes).
>> 
>> I have since upgraded atlas to atlas3.9.32 and lapack to lapack-3.2.2. to
>> fulfill requirements of other numeric intensive  programs I use.  Today  I
>> compiled and installed    R-2.12.0   using the same settings used for
>> R-2.11.1 and these are my findings:-
>> 
>> {The  installed directory is ~42Mbytes  and in the ~/lib directory there is
>> but libR.so of only 2.9 mbytes.  There are no libRlapack.so nor
>> libRblas.so}
>> 
>> 
>> I would be grateful if someone culd explain   the discrepencies   between
>> the two versions of R  and what the requirements are for generating
>> linRlapack.so and libRblas.so  and/or whether these have been superceded.
>> 
>> 
>> thanks in   advance..
> 
> excerpt from /R-2.12.0/src/modules/lapack/README
> 
> (
> The Fortran routines here are extracted from LAPACK 3.1.0, then 3.1.1
> (http://www.netlib.org/lapack and mirrors).
> 
> dlapack?.f are support routines for `real' LAPACK calls
> cmplx.f are support routines for LAPACK calls from complex arithmetic
> routines, that are only used if COMPLEX*16 is supported by the Fortran
> compiler and compatible with the Rcomplex type (guaranteed for f2c users).
> Neither will not be compiled if an external LAPACK is used.
> 
> )
> 
> As I said in my original email,  I  have external atla3.9.32 and lapack-3.2.2.  
> I would be grateful to know if:-
> 
> a) libRblas.so  and libRlapack.so  are now superfluouss  AND  if hey are 

They are not superfluous - they are optional - each in a different way. libRblas is shared BLAS library - i.e., it allows you to swap the BLAS implementation without recompiling R. libRlapack is R's version of the LAPACK in case the BLAS you link against doesn't have LAPACK routines. The presence/absence of each of the above is controlled by the corresponding configure flags (and in case you use auto-detection by the availability and functionality of the BLAS you use).


> b) if one  now links libR.so  to lib{atlas,lapack}.so (or .a)
> 

You can do either -- or you can use shared BLAS - it's entirely up to you. Nothing really changed in recent R - the above applies for quite some time (ever since shared BLAS support was added) so it's very likely that any differences you see are entirely due to your setup, not due to R.

Cheers,
Simon



[Rd] R-.12.0 atlas lapack
Simon Urbanek