Difference between revisions of "ATLAS"

From CBLFS
Jump to navigationJump to search
 
(10 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{| style="text-align: left; background-color: AliceBlue;"
+
{|style="text-align: left; background-color: AliceBlue;"
 
|-
 
|-
 
!Download Source:
 
!Download Source:
| http://www.netlib.org/atlas/atlas{{BLAS-Version}}.tgz
+
|http://downloads.sourceforge.net/math-atlas/atlas{{ATLAS-Version}}.tar.bz2
 
|-
 
|-
!Download Source:
 
| http://www.netlib.org/blas/blas.tgz (F77 source files only, see below)
 
 
|}
 
|}
  
== Introduction to BLAS ==
+
----
 
 
BLAS are '''B'''asic '''L'''inear '''A'''lgebra '''S'''ubprograms written in Fortran77.  There are Level 1 (scalar and vector operations), Level 2 (scalar-matrix operations) and Level 3 (matrix-matrix operations) subprograms.  They are available at [http://www.netlib.org/blas/ as tarballs] of F77 source files and are un-optimized for any particular architecture.  Use the second download source if you want or need these source files.
 
 
 
LAPACK is a '''L'''inear '''A'''lgebra '''PACK'''age that provides routines for solving systems of simultaneous linear equations, least-squares solutions of linear systems of equations, eigenvalue problems, and singular value problems.  LAPACK routines are written so that as much as possible of the computation is performed by calls to the BLAS.  The LAPACK libraries produced by ATLAS are not optimal.  Use the [[LAPACK]] package for optimal LAPACK libraries.
 
 
 
ATLAS (Automatically Tuned Linear Algebra Software) will provide C and FORTRAN interfaces to a BLAS and LAPACK implementation optimized for a specific machine architecture.  The ideal source of BLAS and LAPACK libraries are those provided by the microprocesor vendor such as AMD's [[ACML]].  However, these are not provided under a license that allows re-distribution without written consent from the vendor.
 
 
 
<b>Homepage:</b> http://www.netlib.org/blas/
 
 
 
== Dependencies ==
 
 
 
=== Optional ===
 
  
* [[GCC-3.3]] Benchmarking by the ATLAS maintainers indicates that, with the exception of Core Duo and Pentium M, compiling ATLAS with gcc-3.X [http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27827 produces better x87 code than gcc-4.X].  SSE is preferred over x87, but when x87 is optimized it outperforms SSE in single precision scalar mode.
+
{{Package-Introduction|BLAS are '''B'''asic '''L'''inear '''A'''lgebra '''S'''ubprograms written in Fortran.  There are Level 1 (scalar and vector operations), Level 2 (scalar-matrix operations) and Level 3 (matrix-matrix operations) subprograms. ATLAS (Automatically Tuned Linear Algebra Software) will provide C and FORTRAN interfaces to a BLAS implementation optimized for a specific machine architecture.  The ideal source of BLAS and LAPACK libraries are those provided by the microprocesor vendor such as AMD's [[ACML]].  However, these are not provided under a license that allows re-distribution without written consent from the vendor.|http://www.netlib.org/blas/}}
 
 
== Configuration ==
 
 
 
If you are building BLAS libraries for more than one TARGET architecture, either place each set of libraries in a subdirectory of /usr/lib or give each set a unique name so as not to overwrite earlier versions.
 
  
 
== Non-Multilib ==
 
== Non-Multilib ==
  
Compile the package:
+
First, build the [[LAPACK]] libraries, then compile the package:
 
 
  make
 
  
The configuration is interactive. Simply follow the instructions presented on the screenIf you've installed the FORTRAN provided by gcc-4.0.3 and later use <b>gfortran</b> when the configuration complains that the F77 version it finds is unsuitable.
+
mkdir build &&
 +
cd build &&
 +
../configure --prefix=/usr \
 +
  --with-netlib-lapack=$PWD/../../lapack-{{Lapack-Version}}/lapack_LINUX.a \
 +
-Fa alg -fPIC -b 32 &&
 +
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
 +
make &&
 +
cd lib &&
 +
make shared &&
 +
make ptshared &&
 +
cd ..
  
 
Install the package:
 
Install the package:
  
   make install arch=<TARGET> &&
+
   make install &&
   cp -v lib/<TARGET>/*.a /usr/lib
+
   cp -v lib/*so /usr/lib
 
 
Where <TARGET> will be displayed at the completion of the 'make' step.
 
 
 
Install the API and other documentation.
 
 
 
  install -v -m755 -d /usr/share/doc/ATLAS-{{BLAS-Version}} &&
 
  for doc in doc/*.{ps,txt}; do
 
    cp -v $doc /usr/share/doc/ATLAS-{{BLAS-Version}}
 
  done
 
 
 
The ATLAS compilation and tuning produces several log files in bin/<TARGET>/INSTALL_LOG.  These may be of interest or helpful if the BLAS libraries are found not to be optimal and you seek help from the ATLAS maintainers.  Install them as follows:
 
 
 
  install -v -m755 -d /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOG &&
 
  for log in bin/<TARGET>/INSTALL_LOG/*.LOG; do
 
    cp -v $log /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOG
 
  done
 
  
 
== Multilib ==
 
== Multilib ==
Line 61: Line 35:
 
=== 32Bit ===
 
=== 32Bit ===
  
Compile the package:
+
First, build the [[LAPACK]] libraries, then compile the package:
 
 
  make
 
  
The configuration is interactive. Simply follow the instructions presented on the screenIf you've installed the FORTRAN provided by gcc-4.0.3 and later use <b>gfortran</b> when the configuration complains that the F77 version it finds is unsuitable.
+
mkdir build &&
 +
cd build &&
 +
CC="gcc ${BUILD32}" ../configure --prefix=/usr \
 +
  --with-netlib-lapack=$PWD/../../lapack-{{Lapack-Version}}/lapack_LINUX.a \
 +
-Fa alg -fPIC -b 32 &&
 +
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
 +
make &&
 +
cd lib &&
 +
make shared &&
 +
make ptshared &&
 +
cd ..
  
 
Install the package:
 
Install the package:
  
   make install arch=<TARGET> &&
+
   make install &&
   cp -v lib/<TARGET>/*.a /usr/lib
+
   cp -v lib/*so /usr/lib
 
 
Where <TARGET> will be displayed at the completion of the 'make' step.
 
 
 
The ATLAS compilation and tuning produces several log files in bin/<TARGET>/INSTALL_LOG.  These may be of interest or helpful if the BLAS libraries are found not to be optimal and you seek help from the ATLAS maintainers.  Install them as follows:
 
 
 
  install -v -m755 -d /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOG32 &&
 
  for log in bin/<TARGET>/INSTALL_LOG/*.LOG; do
 
    cp -v $log /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOG32
 
  done
 
  
 
=== N32 ===
 
=== N32 ===
  
Compile the package:
+
First, build the [[LAPACK]] libraries, then compile the package:
 
 
  make
 
  
The configuration is interactiveSimply follow the instructions presented on the screenIf you've installed the FORTRAN provided by gcc-4.0.3 and later use <b>gfortran</b> when the configuration complains that the F77 version it finds is unsuitable.
+
mkdir build &&
 +
cd build &&
 +
CC="gcc ${BUILDN32}" ../configure \
 +
--prefix=/usr --libdir=/usr/lib32 \
 +
  --with-netlib-lapack=$PWD/../../lapack-{{Lapack-Version}}/lapack_LINUX.a \
 +
  -Fa alg -fPIC &&
 +
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
 +
make &&
 +
cd lib &&
 +
make shared &&
 +
make ptshared &&
 +
cd ..
  
 
Install the package:
 
Install the package:
  
   make install arch=<TARGET> &&
+
   make install &&
   cp -v lib/<TARGET>/*.a /usr/lib32
+
   cp -v lib/*so /usr/lib32
  
Where <TARGET> will be displayed at the completion of the 'make' step.
+
=== 64Bit ===
  
The ATLAS compilation and tuning produces several log files in bin/<TARGET>/INSTALL_LOG.  These may be of interest or helpful if the BLAS libraries are found not to be optimal and you seek help from the ATLAS maintainers.  Install them as follows:
+
First, build the [[LAPACK]] libraries, then compile the package:
  
  install -v -m755 -d /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOGN32 &&
+
mkdir build &&
  for log in bin/<TARGET>/INSTALL_LOG/*.LOG; do
+
cd build &&
    cp -v $log /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOGN32
+
CC="gcc ${BUILD64}" ../configure \
  done
+
--prefix=/usr --libdir=/usr/lib64 \
 +
--with-netlib-lapack=$PWD/../../lapack-{{Lapack-Version}}/lapack_LINUX.a \
 +
-Fa alg -fPIC -b 64 &&
 +
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
 +
make &&
 +
cd lib &&
 +
make shared &&
 +
make ptshared &&
 +
cd ..
  
=== 64Bit ===
+
Install the package:
  
Compile the package:
+
  make install &&
 +
  cp -v lib/*so /usr/lib64
  
  make
+
== Configuration Information ==
  
The configuration is interactive. Simply follow the instructions presented on the screen. If you've installed the FORTRAN provided by gcc-4.0.3 and later use <b>gfortran</b> when the configuration complains that the F77 version it finds is unsuitable.
+
Create and install pkgconfig metadata files:
 +
   
 +
  cat > blas.pc.in << "EOF"
 +
prefix=/usr
 +
exec_prefix=${prefix}
 +
libdir=/usr/<LIB>
 +
includedir=${prefix}/include
 +
 +
Name: blas
 +
Description: Automatically Tuned Linear Algebra Software F77 BLAS implementation
 +
Version: 3.8.0
 +
URL: http://math-atlas.sourceforge.net/
 +
Libs: -L${libdir} -latlas -lcblas -lf77blas -lptcblas -lptf77cblas
 +
Libs.private: -lm -lgfortran
 +
EOF
  
Install the package:
+
cat > lapack.pc.in << "EOF"
 +
prefix=/usr
 +
exec_prefix=${prefix}
 +
libdir=/usr/<LIB>
 +
includedir=${prefix}/include
 +
 +
Name: lapack
 +
Description: Linear Algebra PACKage
 +
Version: 3.8.0
 +
URL: http://math-atlas.sourceforge.net/
 +
Libs: -L${libdir} -latlas -llapack
 +
Libs.private: -lm -lgfortran
 +
Cflags: -I${includedir}
 +
EOF
  
  make install arch=<TARGET> &&
+
=== Non-Multilib or 32-Bit ===
  cp -v lib/<TARGET>/*.a /usr/lib64
 
  
Where <TARGET> will be displayed at the completion of the 'make' step.
+
sed -i 's/<LIB>/lib/' blas.pc.in &&
 +
sed -i 's/<LIB>/lib/' lapack.pc.in &&
 +
cp -v blas.pc.in /usr/lib/pkgconfig/blas.pc &&
 +
cp -v lapack.pc.in /usr/lib/pkgconfig/lapack.pc
  
Install the API and other documentation.
+
=== N32 ===
 
 
  install -v -m755 -d /usr/share/doc/ATLAS-{{BLAS-Version}} &&
 
  for doc in doc/*.{ps,txt}; do
 
    cp -v $doc /usr/share/doc/ATLAS-{{BLAS-Version}}
 
  done
 
  
The ATLAS compilation and tuning produces several log files in bin/<TARGET>/INSTALL_LOG. These may be of interest or helpful if the BLAS libraries are found not to be optimal and you seek help from the ATLAS maintainersInstall them as follows:
+
sed -i 's/<LIB>/lib32/' blas.pc.in &&
 
+
  sed -i 's/<LIB>/lib32/' lapack.pc.in &&
  install -v -m755 -d /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOG64 &&
+
cp -v blas.pc.in /usr/lib32/pkgconfig/blas.pc &&
  for log in bin/<TARGET>/INSTALL_LOG/*.LOG; do
+
cp -v lapack.pc.in /usr/lib32/pkgconfig/lapack.pc
    cp -v $log /usr/share/doc/ATLAS-{{BLAS-Version}}/INSTALL_LOG64
+
  done
+
=== 64-Bit ===
  
 +
sed -i 's/<LIB>/lib64/' blas.pc.in &&
 +
sed -i 's/<LIB>/lib64/' lapack.pc.in &&
 +
cp -v blas.pc.in /usr/lib64/pkgconfig/blas.pc &&
 +
cp -v lapack.pc.in /usr/lib64/pkgconfig/lapack.pc
 +
 
== Contents ==
 
== Contents ==
  
Line 137: Line 157:
 
|-valign="top";
 
|-valign="top";
 
!Installed Libraries:
 
!Installed Libraries:
| libatlas.a, libcblas.a, libf77blas.a, liblapack.a
+
| libatlas.{a,so}, libcblas.{a,so}, libf77blas.{a,so}, libptcblas.{a, so} libptf77cblas.{a, so}, liblapack.{a, so}
 
|}
 
|}
  
Line 144: Line 164:
 
{|style="text-align: left"
 
{|style="text-align: left"
 
|-valign="top"
 
|-valign="top"
!libatlas.a:
+
!libatlas
|The main ATLAS library, providing low-level routines for all interface libraries.
+
|is the main ATLAS library, providing low-level routines for all interface libraries.
 
|-valign="top"
 
|-valign="top"
!libcblas.a:
+
!libcblas
|The C library with optimized BLAS functions.
+
|is the C library with optimized BLAS functions.
 
|-valign="top"
 
|-valign="top"
!libf77blas.a:
+
!libf77blas
|The FORTRAN library with optimized BLAS functions.
+
|is the FORTRAN library with optimized BLAS functions.
 
|-valign="top"
 
|-valign="top"
!liblapack.a:
+
!libptcblas
|The LAPACK routines provided by ATLAS.
+
|is the threaded C library with optimized BLAS functions.
 +
|-valign="top"
 +
!libptf77blas
 +
|is the threaded FORTRAN library with optimized BLAS functions.
 +
|-valign="top"
 +
!liblapack
 +
|is the LAPACK library.
 
|}
 
|}
 +
 +
[[Category:Science_Engineering]]

Latest revision as of 09:43, 20 March 2010

Download Source: http://downloads.sourceforge.net/math-atlas/atlas3.8.0.tar.bz2

Introduction to ATLAS

BLAS are Basic Linear Algebra Subprograms written in Fortran. There are Level 1 (scalar and vector operations), Level 2 (scalar-matrix operations) and Level 3 (matrix-matrix operations) subprograms. ATLAS (Automatically Tuned Linear Algebra Software) will provide C and FORTRAN interfaces to a BLAS implementation optimized for a specific machine architecture. The ideal source of BLAS and LAPACK libraries are those provided by the microprocesor vendor such as AMD's ACML. However, these are not provided under a license that allows re-distribution without written consent from the vendor.

Project Homepage: http://www.netlib.org/blas/

Non-Multilib

First, build the LAPACK libraries, then compile the package:

mkdir build &&
cd build &&
../configure --prefix=/usr \
--with-netlib-lapack=$PWD/../../lapack-3.1.1/lapack_LINUX.a \
-Fa alg -fPIC -b 32 &&
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
make &&
cd lib &&
make shared &&
make ptshared &&
cd ..

Install the package:

 make install &&
 cp -v lib/*so /usr/lib

Multilib

32Bit

First, build the LAPACK libraries, then compile the package:

mkdir build &&
cd build &&
CC="gcc ${BUILD32}" ../configure --prefix=/usr \
--with-netlib-lapack=$PWD/../../lapack-3.1.1/lapack_LINUX.a \
-Fa alg -fPIC -b 32 &&
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
make &&
cd lib &&
make shared &&
make ptshared &&
cd ..

Install the package:

 make install &&
 cp -v lib/*so /usr/lib

N32

First, build the LAPACK libraries, then compile the package:

mkdir build &&
cd build &&
CC="gcc ${BUILDN32}" ../configure \
--prefix=/usr --libdir=/usr/lib32 \
--with-netlib-lapack=$PWD/../../lapack-3.1.1/lapack_LINUX.a \
-Fa alg -fPIC &&
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
make &&
cd lib &&
make shared &&
make ptshared &&
cd ..

Install the package:

 make install &&
 cp -v lib/*so /usr/lib32

64Bit

First, build the LAPACK libraries, then compile the package:

mkdir build &&
cd build &&
CC="gcc ${BUILD64}" ../configure \
--prefix=/usr --libdir=/usr/lib64 \
--with-netlib-lapack=$PWD/../../lapack-3.1.1/lapack_LINUX.a \
-Fa alg -fPIC -b 64 &&
sed -i "/RANLIB/s/echo/ranlib/" Make.inc &&
make &&
cd lib &&
make shared &&
make ptshared &&
cd ..

Install the package:

 make install &&
 cp -v lib/*so /usr/lib64

Configuration Information

Create and install pkgconfig metadata files:

cat > blas.pc.in << "EOF"
prefix=/usr
exec_prefix=${prefix}
libdir=/usr/<LIB>
includedir=${prefix}/include

Name: blas
Description: Automatically Tuned Linear Algebra Software F77 BLAS implementation
Version: 3.8.0
URL: http://math-atlas.sourceforge.net/
Libs: -L${libdir} -latlas -lcblas -lf77blas -lptcblas -lptf77cblas
Libs.private: -lm -lgfortran
EOF
cat > lapack.pc.in << "EOF"
prefix=/usr
exec_prefix=${prefix}
libdir=/usr/<LIB>
includedir=${prefix}/include

Name: lapack
Description: Linear Algebra PACKage
Version: 3.8.0
URL: http://math-atlas.sourceforge.net/
Libs: -L${libdir} -latlas -llapack 
Libs.private: -lm -lgfortran
Cflags: -I${includedir}
EOF

Non-Multilib or 32-Bit

sed -i 's/<LIB>/lib/' blas.pc.in &&
sed -i 's/<LIB>/lib/' lapack.pc.in &&
cp -v blas.pc.in /usr/lib/pkgconfig/blas.pc &&
cp -v lapack.pc.in /usr/lib/pkgconfig/lapack.pc

N32

sed -i 's/<LIB>/lib32/' blas.pc.in &&
sed -i 's/<LIB>/lib32/' lapack.pc.in &&
cp -v blas.pc.in /usr/lib32/pkgconfig/blas.pc &&
cp -v lapack.pc.in /usr/lib32/pkgconfig/lapack.pc

64-Bit

sed -i 's/<LIB>/lib64/' blas.pc.in &&
sed -i 's/<LIB>/lib64/' lapack.pc.in &&
cp -v blas.pc.in /usr/lib64/pkgconfig/blas.pc &&
cp -v lapack.pc.in /usr/lib64/pkgconfig/lapack.pc

Contents

Installed Libraries: libatlas.{a,so}, libcblas.{a,so}, libf77blas.{a,so}, libptcblas.{a, so} libptf77cblas.{a, so}, liblapack.{a, so}

Short Description

libatlas is the main ATLAS library, providing low-level routines for all interface libraries.
libcblas is the C library with optimized BLAS functions.
libf77blas is the FORTRAN library with optimized BLAS functions.
libptcblas is the threaded C library with optimized BLAS functions.
libptf77blas is the threaded FORTRAN library with optimized BLAS functions.
liblapack is the LAPACK library.
Retrieved from "?title=ATLAS&oldid=19977"