如何在Cray XC上编译VASP 5.4.1

时间:2015-07-16 13:40:15

标签: compilation cray

我想在Cray XC MPP机器上编译最新版本的VASP 5(5.4.1)。有没有人有我可以使用的设置? VASP发行版没有为Cray提供示例。

构建系统已从5.3.5版本更改。

1 个答案:

答案 0 :(得分:1)

完整的编译说明可在ARCHER(http://www.archer.ac.uk)网站上找到:

http://www.archer.ac.uk/documentation/software/vasp/compiling_5-4-1-phase2.php

但简而言之:

  1. 下载并修补源代码

  2. 切换到英特尔编程环境并加载fftw模块:

    module swap PrgEnv-cray PrgEnv-intel
    module load fftw
    
  3. 使用以下设置创建“makefile.include”:

    # Precompiler options
    CPP_OPTIONS= -DMPI -DHOST=\"CrayXC-Intel\" \
                 -DIFC \
                 -DCACHE_SIZE=2000 \
                 -DPGF90 \
                 -Davoidalloc \
                 -DMPI_BLOCK=8000 \
                 -DscaLAPACK \
                 -Duse_collective \
                 -DnoAugXCmeta \
                 -Duse_bse_te \
                 -Duse_shmem \
                 -Dtbdyn
    
    CPP        = fpp -f_com=no -free -w0  $*$(FUFFIX) $*$(SUFFIX) $(CPP_OPTIONS)
    
    FC         = ftn
    FCL        = ftn
    
    FREE       = -free -names lowercase
    
    FFLAGS     = -assume byterecl
    OFLAG      = -O3 -ip -fno-alias -unroll-aggressive -opt-prefetch -use-intel-optimized-headers -no-prec-div
    OFLAG_IN   = $(OFLAG)
    DEBUG      = -O0
    
    MKL_PATH   = $(MKLROOT)/lib/intel64
    BLAS       =
    LAPACK     =
    BLACS      =
    SCALAPACK  =
    
    OBJECTS    = fftmpiw.o fftmpi_map.o fftw3d.o fft3dlib.o
    INCS       =
    
    LLIBS      = ${MKL_PATH}/libmkl_blas95_lp64.a ${MKL_PATH}/libmkl_lapack95_lp64.a \
                 ${MKL_PATH}/libmkl_scalapack_lp64.a  \
                 -Wl,--start-group ${MKL_PATH}/libmkl_intel_lp64.a \
                 ${MKL_PATH}/libmkl_sequential.a ${MKL_PATH}/libmkl_core.a \
                 ${MKL_PATH}/libmkl_blacs_intelmpi_lp64.a  -Wl,--end-group
    
    OBJECTS_O1 += fft3dfurth.o fftw3d.o fftmpi.o fftmpiw.o
    OBJECTS_O2 += fft3dlib.o
    
    # For what used to be vasp.5.lib
    CPP_LIB    = $(CPP)
    FC_LIB     = $(FC)
    CC_LIB     = cc
    CFLAGS_LIB = -O
    FFLAGS_LIB = -O1
    FREE_LIB   = $(FREE)
    
    OBJECTS_LIB= linpack_double.o getshmem.o
    
    # Normally no need to change this
    SRCDIR     = ../../src
    BINDIR     = ../../bin
    
  4. 编译代码

    make all