Differences between revisions 2 and 3
Revision 2 as of 2009-10-02 08:17:24
Size: 6502
Editor: StefanTibus
Revision 3 as of 2009-10-02 08:37:20
Size: 6798
Editor: StefanTibus
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
  * Hardware: !SunFire 2900 nodes with UltraSPARC IV+ processors.
  * Operating system: Sun Solaris 10 (5.10)
  * Compiler: Sun Studio 12 (update 1)
  * Hardware: ''!SunFire 2900'' nodes with [[http://www.sun.com/processors/UltraSPARC-IVplus/|UltraSPARC IV+]] processors
  * Operating system: [[http://www.sun.com/software/solaris/|Sun Solaris]] 10 (5.10)
  * Compiler: [[http://developers.sun.com/sunstudio/|Sun Studio]] 12 (update 1)
Line 7: Line 7:
    * BLAS/LAPACK: Sun Performance Library
    * MPI: Sun HPC Cluster Tools
    * BLAS/LAPACK: [[http://developers.sun.com/sunstudio/overview/topics/computing.jsp|Sun Performance Library]] (Sun Studio)
    * MPI: ''Sun MPI'' 7.0 ([[http://www.sun.com/software/products/clustertools/|Sun HPC Cluster Tools]] 6)

Installation on Solaris/SPARC

Problems and patches

  • SUNDIAL`s configure script fails on a compiler optimization option. sundials_ss12hpc.diff

  • The PETSc configure scripts use a deprecated compiler option for 64bit targets. petsc_ss12hpc.diff

  • TAO makes use of isinf (defined by the C99 standard) which is not supported by the Sun Studio 12 C++ compiler. tao_ss12hpc.diff

  • magpar makes use of variable length arrays (defined by the C99 standard) which are not supported by the Sun Studio 12 C++ compiler. src_ss12hpc.diff

Step-by-step procedure

Prepare directory and download magpar

cd $HOME  # $HOME
mkdir magpar-0.8
cd magpar-0.8  # $HOME/magpar-0.8
wget http://www.magpar.net/static/magpar/download/magpar-0_8.tar.gz
tar xzf magpar-0_8.tar.gz
cd magpar-0_8  # $HOME/magpar-0.8/magpar-0_8
MAGPAR_HOME=$PWD; export MAGPAR_HOME  # $HOME/magpar-0.8/magpar-0_8
PD=$MAGPAR_HOME/libs; export PD  # $HOME/magpar-0.8/magpar-0_8/libs


cd $PD  # $HOME/magpar-0.8/magpar-0_8/libs
wget -N http://glaros.dtc.umn.edu/gkhome/fetch/sw/parmetis/$lib.tar.gz
tar xzf $lib.tar.gz
cd $lib  # $HOME/magpar-0.8/magpar-0_8/libs/ParMetis-3.1.1

ld needs the deprecated -xarch=v9b switch to use the correct library paths for 64bit!

#make "CC=mpcc -g -m64 -xarch=sparcvis2" "LD=mpcc -xarch=v9b" "XTRALIBS=-lmpi" "OPTFLAGS=-fast -xtarget=ultra4plus"  # with symbol table
make "CC=mpcc -m64 -xarch=sparcvis2" "LD=mpcc -xarch=v9b" "XTRALIBS=-lmpi" "OPTFLAGS=-fast -xtarget=ultra4plus"


cd $PD  # $HOME/magpar-0.8/magpar-0_8/libs
# get sundials-2.3.0.tar.gz
tar xzf $lib.tar.gz
cd $lib  # $HOME/magpar-0.8/magpar-0_8/libs/sundials-2.3.0

Sun Studio's -fast expands to:

-fns  -fsimple=2 -xarch -xbuiltin=%all -xcache -xchip -xdepend -xlibmil -xlibmopt -xmemalign -xO5 -xtarget=native

-xlibmil has problems with return fabs ();. Changing this to return fabs (1); works, but may not be what was intended by the configure script.

patch -p1 < ../../../sundials_ss12hpc.diff
#./configure --prefix=$PD/sundials --with-cflags="-g -fast -xtarget=ultra4plus -m64 -xarch=sparcvis2" --with-ldflags="-xarch=v9b" --with-mpicc=mpcc --with-mpif77=mpf77 --with-mpi-libs="-lmpi"  # with symbol table
./configure --prefix=$PD/sundials --with-cflags="-fast -xtarget=ultra4plus -m64 -xarch=sparcvis2" --with-ldflags="-xarch=v9b" --with-mpicc=mpcc --with-mpif77=mpf77 --with-mpi-libs="-lmpi"
make && make -i install


cd $PD  # $HOME/magpar-0.8/magpar-0_8/libs
wget ftp://ftp.mcs.anl.gov/pub/petsc/release-snapshots/$lib.tar.gz
tar xzf $lib.tar.gz
cd $lib  # $HOME/magpar-0.8/magpar-0_8/libs/petsc-2.3.3-p15
PETSC_DIR=$PD/$lib; export PETSC_DIR  # $HOME/magpar-0.8/magpar-0_8/libs/petsc-2.3.3-p15

The configure scripts use the deprecated -xarch=v9 switch for 64bit targets. Fixed to use -m64 instead.

patch -p1 < ../../../petsc_ss12hpc.diff

Give all options as parameters to the configure script instead of writing a configuration file.


With --with-debugging=0 magpar crashes.

#./config/configure.py --with-gnu-compilers=0 --with-64-bit-pointers=1 --with-precision=double --with-blas-lapack-lib=libsunperf.a --with-mpi-root="/opt/SUNWhpc" --with-x=0 --with-clanguage=C++ --with-debugging=1 --CC=mpcc --CXX=mpCC --FC=mpf77 --CFLAGS="-g -m64 -xarch=sparcvis2" --CXXFLAGS="-g -m64 -xarch=sparcvis2" --FFLAGS="-g -m64  -xarch=sparcvis2" --LDFLAGS="-xarch=v9b" --COPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" --CXXOPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" --FOPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" --with-shared=0 --with-dynamic=0  # debug version with symbol table
./config/configure.py --with-gnu-compilers=0 --with-64-bit-pointers=1 --with-precision=double --with-blas-lapack-lib=libsunperf.a --with-mpi-root="/opt/SUNWhpc" --with-x=0 --with-clanguage=C++ --with-debugging=1 --CC=mpcc --CXX=mpCC --FC=mpf77 --CFLAGS="-m64 -xarch=sparcvis2" --CXXFLAGS="-m64 -xarch=sparcvis2" --FFLAGS="-m64  -xarch=sparcvis2" --LDFLAGS="-xarch=v9b" --COPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" --CXXOPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" --FOPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" --with-shared=0 --with-dynamic=0
PETSC_ARCH=solaris2.10-cxx-debug; export PETSC_ARCH  # debug version
make all


cd $PD  # $HOME/magpar-0.8/magpar-0_8/libs
wget -N http://www-unix.mcs.anl.gov/tao/download/$lib.tar.gz
tar xzf $lib.tar.gz
cd $lib  # $HOME/magpar-0.8/magpar-0_8/libs/tao-1.9
TAO_DIR=$PD/$lib; export TAO_DIR  # $HOME/magpar-0.8/magpar-0_8/libs/tao-1.9

Sun Studio's C++ compiler does not provide isinf.

patch -p1 < ../../../tao_ss12hpc.diff
make  # Options are taken from PETSc.


cd $MAGPAR_HOME/src  # $HOME/magpar-0.8/magpar-0_8/src
cp Makefile.in.defaults Makefile.in.ss12hpc
Sun Studio's C++ compiler does not support variable length arrays.

For workaround see http://forums.sun.com/thread.jspa?threadID=5348093.


PETSC_ARCH has to be adjusted in Makefile.

patch -p1 < ../../src_ss12hpc.diff
cp -p Makefile.in.ss12hpc Makefile.in.$HOSTNAME

make varinfo | less  # Check compilation options.

Some options are taken from PETSc.

#CC=mpcc CXX=mpCC F77=mpf77 FC=mpf77 F90=mpf90 CFLAGS="-g -m64 -xarch=sparcvis2 -DPNG -DZLIB" OPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" EXTERNAL_LIB="-lpng -lz" make  # with symbol table
CC=mpcc CXX=mpCC F77=mpf77 FC=mpf77 F90=mpf90 CFLAGS="-m64 -xarch=sparcvis2 -DPNG -DZLIB" OPTFLAGS="-fast -xtarget=ultra4plus -xlic_lib=sunperf" EXTERNAL_LIB="-lpng -lz" make

Run magpar by calling mprun -np <x> magpar.exe.

Download patches

There are 4 attachment(s) stored for this page.

  • [get | view] (2009-10-01 18:17:24, 1.5 KB) [[attachment:petsc_ss12hpc.diff]]
  • [get | view] (2009-10-01 18:17:46, 4.4 KB) [[attachment:src_ss12hpc.diff]]
  • [get | view] (2009-10-01 18:17:09, 0.3 KB) [[attachment:sundials_ss12hpc.diff]]
  • [get | view] (2009-10-01 18:17:30, 0.9 KB) [[attachment:tao_ss12hpc.diff]]

MagparWiki: InstallationOnSolarisSPARC (last edited 2009-10-02 08:37:20 by StefanTibus)

Copyright (C) Werner Scholz 2010