Skip to content
mattbement edited this page Mar 26, 2019 · 15 revisions

Welcome to the ForTrilinos wiki!

ForTrilinos build on Summit (as of Mar 26, 2019)

Load the following modules: gcc netlib-lapack cmake

Generally follow the instruction from here. You may need to checkout whatever version of Trilinos is in ForTrilinos/docker/trilinos_version. Grab the configure script from here, then add the following to the ARGS section:

-D MPI_EXEC=/sw/summit/xalt/1.1.3/bin/jsrun -D MPI_EXEC_NUMPROCS_FLAG="-n"

It should then build OK, and if you get an interactive compute login (e.g. bsub -W 1:00 -nnodes 1 -P MYSUPERAWESOMEPROJECT -Is /bin/bash), ctest should pass.

Standalone ForTrilinos build on Titan

Per @mattbement instructions:

First, swap modules:

$ module swap PrgEnv-pgi PrgEnv-gnu
$ module load cmake3/3.9.0 acml

Then, configure using the following script

#!/usr/bin/env bash

EXTRA_ARGS=$@

rm -f CMakeCache.txt
rm -rf CMakeFiles/

ARGS=(
    -D CMAKE_BUILD_TYPE=Debug

    -D BUILD_SHARED_LIBS=ON
    -D MPI_EXEC="/sw/xk6/xalt/0.7.5/bin/aprun"
    -D MPI_EXEC_NUMPROCS_FLAG="-n"

    ### COMPILERS AND FLAGS ###
    -D Trilinos_ENABLE_Fortran=ON
    -D CMAKE_CXX_FLAGS="-Wall -Wpedantic"

    ### TPLs ###
    -D TPL_ENABLE_MPI=ON
    -D TPL_ENABLE_BLAS=ON
      -D BLAS_LIBRARY_NAMES=acml
      -D BLAS_LIBRARY_DIRS=/opt/acml/5.3.1/gfortran64/lib
    -D TPL_ENABLE_LAPACK=ON
      -D LAPACK_LIBRARY_NAMES=acml
      -D LAPACK_LIBRARY_DIRS=/opt/acml/5.3.1/gfortran64/lib

    ### ETI ###
    -D Trilinos_ENABLE_EXPLICIT_INSTANTIATION=ON

    ### PACKAGES CONFIGURATION ###
    -D Trilinos_ENABLE_ALL_PACKAGES=OFF
    -D Trilinos_ENABLE_ALL_OPTIONAL_PACKAGES=OFF

    -D Trilinos_ENABLE_TESTS=OFF
    -D Trilinos_ENABLE_EXAMPLES=OFF

    -D Trilinos_ENABLE_Amesos2=ON
    -D Trilinos_ENABLE_Anasazi=ON
    -D Trilinos_ENABLE_Belos=ON
    -D Trilinos_ENABLE_Epetra=ON
    -D Trilinos_ENABLE_Ifpack2=ON
    -D Trilinos_ENABLE_MueLu=ON
    -D Trilinos_ENABLE_Stratimikos=ON
    -D Trilinos_ENABLE_Tpetra=ON
    -D Trilinos_ENABLE_Thyra=ON

    ### FORTRILINOS ###
    -D Trilinos_ENABLE_ForTrilinos=ON
        -D ForTrilinos_ENABLE_EXAMPLES=ON
        -D ForTrilinos_ENABLE_TESTS=ON
    )
cmake "${ARGS[@]}" $EXTRA_ARGS ..

ACME/ForTrilinos build on Titan with the GNU compiler

Run the following commands to setup the environment:

module unload cmake
module unload hdf5 cray-hdf5 
module unload cray-hdf5-parallel
module unload netcdf
module unload python
module unload cray-shmem
module unload cray-mpich cray-mpich2
module unload netcdf-hdf5parallel cray-netcdf-hdf5parallel cray-parallel-netcdf cray-hdf5-parallel
module unload boost 
module unload dynamic-link
module unload gcc

module load cmake3/3.9.0
module swap PrgEnv-pgi PrgEnv-gnu
module load cray-shmem
module load cray-mpich
module load gcc/6.3.0
module load cray-hdf5-parallel/1.10.0.3
module load cray-netcdf-hdf5parallel/4.4.1.1.3
module load python
module load boost/1.57.0
module load acml

Note that if you don't have PrgEnv-pgi loaded, you may need to replace the swap command with load.

Then, configure using the following script:

#!/usr/bin/env bash
#
echo "Netcdf dir = " ${NETCDF_DIR}

EXTRA_ARGS=$@

rm -f CMakeCache.txt
rm -rf CMakefiles/

ARGS=(
      -D CMAKE_INSTALL_PREFIX=/lustre/atlas1/cli106/proj-shared/4ue/Trilinos/reg_build/install
      -D CMAKE_BUILD_TYPE=Debug

      -D BUILD_SHARED_LIBS=ON

      -D Trilinos_ENABLE_Fortran=ON
      -D CMAKE_C_COMPILER:FILEPATH="cc"
      -D CMAKE_CXX_COMPILER:FILEPATH="CC"
      -D CMAKE_Fortran_COMPILER:FILEPATH="ftn"
      -D CMAKE_CXX_FLAGS="-Wall -Wpedantic"

      -D Trilinos_ENABLE_Export_Makefiles:BOOL=ON

      -D Trilinos_WARNINGS_AS_ERRORS_FLAGS:STRING=""
      -D CMAKE_VERBOSE_MAKEFILE:BOOL=OFF
      -D Trilinos_VERBOSE_CONFIGURE:BOOL=OFF

    ### TPLs ###
      -D TPL_ENABLE_MPI=ON
        -D MPI_EXEC="/sw/xk6/xalt/0.7.5/bin/aprun"
        -D MPI_EXEC_NUMPROCS_FLAG="-n"
      -D TPL_ENABLE_BLAS=ON
        -D BLAS_LIBRARY_NAMES=acml
        -D BLAS_LIBRARY_DIRS=/opt/acml/5.3.1/gfortran64/lib
      -D TPL_ENABLE_LAPACK=ON
        -D LAPACK_LIBRARY_NAMES=acml
        -D LAPACK_LIBRARY_DIRS=/opt/acml/5.3.1/gfortran64/lib
      -D TPL_ENABLE_Boost:BOOL=OFF
      -D TPL_ENABLE_Netcdf:BOOL=ON
        -D Netcdf_INCLUDE_DIRS="${NETCDF_DIR}/include"
        -D Netcdf_LIBRARY_DIRS="${NETCDF_DIR}/lib"
      -D TPL_ENABLE_Pthread:BOOL=OFF
      -D TPL_ENABLE_BinUtils:BOOL=OFF

      -D Trilinos_ENABLE_EXPLICIT_INSTANTIATION=ON

      -D Trilinos_ENABLE_ALL_PACKAGES:BOOL=OFF
      -D Trilinos_ENABLE_ALL_OPTIONAL_PACKAGES:BOOL=OFF

      -D Trilinos_ENABLE_Teuchos:BOOL=ON
      -D HAVE_TEUCHOS_COMM_TIMERS=ON
      -D Trilinos_ENABLE_Shards:BOOL=ON
      -D Trilinos_ENABLE_Sacado:BOOL=ON
      -D Trilinos_ENABLE_Epetra:BOOL=ON
      -D Trilinos_ENABLE_EpetraExt:BOOL=ON
      -D Trilinos_ENABLE_Ifpack:BOOL=ON
      -D Trilinos_ENABLE_AztecOO:BOOL=ON
      -D Trilinos_ENABLE_Amesos:BOOL=ON
      -D Trilinos_ENABLE_Anasazi:BOOL=ON
      -D Trilinos_ENABLE_Belos:BOOL=ON
      -D Trilinos_ENABLE_Phalanx:BOOL=OFF
      -D Trilinos_ENABLE_Intrepid:BOOL=ON
      -D Trilinos_ENABLE_ML:BOOL=ON
      -D Trilinos_ENABLE_NOX:BOOL=ON
      -D Trilinos_ENABLE_Stratimikos:BOOL=ON
      -D Trilinos_ENABLE_Thyra:BOOL=ON
      -D Trilinos_ENABLE_Rythmos:BOOL=ON
      -D Trilinos_ENABLE_MOOCHO:BOOL=ON
      -D Trilinos_ENABLE_OptiPack:BOOL=ON
      -D Trilinos_ENABLE_GlobiPack:BOOL=ON
      -D Trilinos_ENABLE_Stokhos:BOOL=ON
      -D Trilinos_ENABLE_Isorropia:BOOL=ON
      -D Trilinos_ENABLE_Piro:BOOL=ON
      -D Trilinos_ENABLE_Teko:BOOL=ON
      -D Trilinos_ENABLE_STK:BOOL=OFF
      -D TriKota_ENABLE_DakotaCMake:BOOL=OFF
      -D DAKOTA_ENABLE_TESTS:BOOL=OFF
      -D TPL_FIND_SHARED_LIBS:BOOL=OFF

      -D Trilinos_ENABLE_SEACASIoss:BOOL=OFF
      -D Trilinos_ENABLE_ThreadPool:STRING="ON"
      -D Trilinos_ENABLE_Pamgen:BOOL=ON

      -D Trilinos_ENABLE_Mesquite:BOOL=OFF
      -D Trilinos_ENABLE_Zoltan:BOOL=ON
      -D Trilinos_ENABLE_FEI:BOOL=OFF

      -D Trilinos_ENABLE_TESTS:BOOL=OFF
      -D Piro_ENABLE_TESTS:BOOL=OFF
      -D Trilinos_ENABLE_EXAMPLES:BOOL=OFF

      -D Anasazi_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D AztecOO_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D Belos_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D Ifpack_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D NOX_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D Phalanx_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=OFF
      -D Rythmos_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D Stokhos_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D Stratimikos_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D Thyra_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON
      -D Trilinos_ENABLE_TEUCHOS_TIME_MONITOR:BOOL=ON

    ### FORTRILINOS ###
      -D Trilinos_ENABLE_ForTrilinos=ON
      -D ForTrilinos_ENABLE_EXAMPLES=ON
      -D ForTrilinos_ENABLE_TESTS=ON

)
cmake "${ARGS[@]}" EXTRA_ARGS=$@ ..

ACME/ForTrilinos build on Titan with the PGI compiler

Run the following commands to setup the environment:

module rm PrgEnv-intel
module rm pgi
module rm PrgEnv-pgi
module rm PrgEnv-cray
module rm PrgEnv-gnu
module rm PrgEnv-pathscale
module rm intel
module rm cray
module rm pathscale
module rm cray-libsci
module rm cray-netcdf
module rm cray-netcdf-hdf5parallel
module rm cray-parallel-netcdf

module unload cmake
module unload hdf5 cray-hdf5
module unload cray-hdf5-parallel
module unload netcdf
module unload python
module unload cray-shmem
module unload cray-mpich cray-mpich2
module unload netcdf-hdf5parallel cray-netcdf-hdf5parallel cray-parallel-netcdf cray-hdf5-parallel
module unload boost
module unload dynamic-link
module unload gcc

module load PrgEnv-pgi
#module switch pgi pgi/15.3
module load cray-mpich/7.6.3
module switch cray-libsci cray-libsci/16.11.1
module load esmf/5.2.0rp2
module switch atp atp/2.1.1
module load cmake3/3.9.0
module load cray-shmem
module load cray-hdf5-parallel/1.10.0.3
module load cray-netcdf-hdf5parallel/4.4.1.1.3
module load python
module load boost/1.57.0
module load acml

Then, configure using the following script:

WILL FILL IN when its working.