Page 1 of 1

convert utility not found- ffttest fail

Posted: Thu Sep 11, 2008 6:26 am
by PratikDhuvad
Dear All,
We are trying to compile VASP.4.6. It compiles successfully!! with following make file but failes to compile ffttest and dgemmtest.

system:
- dual cpu - Intel Xeon Quadcore, so 8 cores in sum in
- Red-Hat linux 5 (X86-64), 64 bit
- Intel Fortran-Compiler 10.1
- Intel C/C++-Compiler 10.1
- LAM-MPI 7.1.4
- Intel MKL 10.0.1.014
- Vasp 4.6

steps:
-i have already Working lam-mpi with PWSCF
-Working MKL
-vasp library builded successfully
*****************************************************************************************
makefile :
.SUFFIXES: .inc .f .f90 .F
#-----------------------------------------------------------------------
# Makefile for Intel Fortran compiler for P4 systems
.
.
.
# 3c) mindblowing fast SSE2 (4 GFlops on P4, 2.53 GHz)
# Kazushige Goto's BLAS
# http://www.cs.utexas.edu/users/kgoto/signup_first.html
#
#-----------------------------------------------------------------------

# all CPP processed fortran files have the extension .f90
SUFFIX=.f90

#-----------------------------------------------------------------------
# fortran compiler and linker
#-----------------------------------------------------------------------
#FC=/opt/intel/fce/10.1.012/bin/ifort
# fortran linker
#FCL=$(FC)


#-----------------------------------------------------------------------
# whereis CPP ?? (I need CPP, can't use gcc with proper options)
# that's the location of gcc for SUSE 5.3
#
# CPP_ = /usr/lib/gcc-lib/i486-linux/2.7.2/cpp -P -C
#
# that's probably the right line for some Red Hat distribution:
#
# CPP_ = /usr/lib/gcc-lib/i386-redhat-linux/2.7.2.3/cpp -P -C
#
# SUSE X.X, maybe some Red Hat distributions:

CPP_ = ./preprocess <$*.F | /usr/bin/cpp -P -C -traditional >$*$(SUFFIX)

#-----------------------------------------------------------------------
# possible options for CPP:
.
..
# RACCMU_DGEMV use DGEMV instead of DGEMM in RACC (depends on used BLAS)
#-----------------------------------------------------------------------

CPP = $(CPP_) -DHOST=\"LinuxIFC\" \
-Dkind8 -DNGXhalf -DCACHE_SIZE=12000 -Davoidalloc -DMPI -DIFC \
-DRPROMU_DGEMV -DRACCMU_DGEMV

#-----------------------------------------------------------------------
# general fortran flags (there must a trailing blank on this line)
#-----------------------------------------------------------------------

FFLAGS = -FR -lowercase -assume byterecl

#-----------------------------------------------------------------------
# optimization
.
..
.
# -tpp7 P4 optimization
#-----------------------------------------------------------------------

OFLAG=-O1 -xW -tpp7

OFLAG_HIGH = $(OFLAG)
OBJ_HIGH =

OBJ_NOOPT =
DEBUG = -FR -O0
INLINE = $(OFLAG)

#-----------------------------------------------------------------------
# the following lines specify the position of BLAS and LAPACK
# on P4, VASP works fastest with the libgoto library
# so that's what I recommend
#-----------------------------------------------------------------------

# Atlas based libraries
#ATLASHOME= $(HOME)/archives/BLAS_OPT/ATLAS/lib/Linux_P4SSE2/
#BLAS= -L$(ATLASHOME) -lf77blas -latlas

# use specific libraries (default library path might point to other libraries)
#BLAS= $(ATLASHOME)/libf77blas.a $(ATLASHOME)/libatlas.a

# use the mkl Intel libraries for p4 (www.intel.com)
# mkl.5.1
# set -DRPROMU_DGEMV -DRACCMU_DGEMV in the CPP lines
BLAS=-L/opt/intel/mkl/10.0.1.014/lib/em64t/ -lmkl_em64t -lguide -lpthread

# mkl.5.2 requires also to -lguide library
# set -DRPROMU_DGEMV -DRACCMU_DGEMV in the CPP lines
#BLAS=-L/opt/intel/mkl/lib/32 -lmkl_p4 -lguide -lpthread

# even faster Kazushige Goto's BLAS
# http://www.cs.utexas.edu/users/kgoto/signup_first.html
#BLAS= /opt/libs/libgoto/libgoto_p4_512-r0.6.so

# LAPACK, simplest use vasp.4.lib/lapack_double
LAPACK= ../vasp.4.lib/lapack_double.o

# use atlas optimized part of lapack
#LAPACK= ../vasp.4.lib/lapack_atlas.o -llapack -lcblas

# use the mkl Intel lapack
#LAPACK=/opt/intel/mkl/10.0.1.014/lib/em64t/libmkl_lapack.a

#-----------------------------------------------------------------------

LIB = -L../vasp.4.lib -ldmy \
../vasp.4.lib/linpack_double.o $(LAPACK) \
$(BLAS)

# options for linking (for compiler version 6.X, 7.1) nothing is required
LINK =-L/opt/intel/fce/10.1.012/lib -lsvml
# compiler version 7.0 generates some vector statments which are located
# in the svml library, add the LIBPATH and the library (just in case)
#LINK = -L/opt/intel/compiler70/ia32/lib/ -lsvml

#-----------------------------------------------------------------------
# fft libraries:
# VASP.4.6 can use fftw.3.0.X (http://www.fftw.org)
# since this version is faster on P4 machines, we recommend to use it
#-----------------------------------------------------------------------

#FFT3D = fft3dfurth.o fft3dlib.o
FFT3D = fftmpiw.o fftmpi_map.o fft3dlib.o /opt/intel/mkl/10.0.1.014/lib/em64t/libfftw3xf_intel.a


#=======================================================================
# MPI section, uncomment the following lines
.
..
..
# suggested above, you can use the following line
#-----------------------------------------------------------------------

FC=/opt/MPI/lam-7.1.4/lam/bin/mpif90
FCL=$(FC)

#-----------------------------------------------------------------------
# additional options for CPP in parallel version (see also above):
# NGZhalf charge density reduced in Z direction
# wNGZhalf gamma point only reduced in Z direction
# scaLAPACK use scaLAPACK (usually slower on 100 Mbit Net)
#-----------------------------------------------------------------------

CPP = $(CPP_) -DMPI -DHOST=\"LinuxIFC\" -DIFC \
-Dkind8 -DNGZhalf -DCACHE_SIZE=4000 -DPGF90 -Davoidalloc \
-DMPI_BLOCK=500 \
# -DRPROMU_DGEMV -DRACCMU_DGEMV -DscaLAPACK

#-----------------------------------------------------------------------
# location of SCALAPACK
# if you do not use SCALAPACK simply uncomment the line SCA
#-----------------------------------------------------------------------

BLACS=$(HOME)/archives/SCALAPACK/BLACS/
SCA_=$(HOME)/archives/SCALAPACK/SCALAPACK

#SCA= $(SCA_)/libscalapack.a \
#$(BLACS)/LIB/blacsF77init_MPI-LINUX-0.a $(BLACS)/LIB/blacs_MPI-LINUX-0.a $(BLACS)/LIB/blacsF77init_MPI-LINUX-0.a

SCA=
#-----------------------------------------------------------------------
# libraries for mpi
#-----------------------------------------------------------------------

LIB = -L../vasp.4.lib -ldmy \
../vasp.4.lib/linpack_double.o $(LAPACK) \
$(SCA) $(BLAS)

# FFT: fftmpi.o with fft3dlib of Juergen Furthmueller
FFT3D = fftmpi.o fftmpi_map.o fft3dlib.o /opt/intel/mkl/10.0.1.014/lib/em64t/libfftw3xf_intel.a

# fftw.3.0.1 is slighly faster and should be used if available
#FFT3D = fftmpiw.o fftmpi_map.o fft3dlib.o /opt/intel/mkl/10.0.1.014/lib/em64t/libfftw3xf_intel.a

#-----------------------------------------------------------------------
# general rules and compile lines
.
...
.
No change in all these sections..
*********************************************************************************

Compiling with this make file does not end with any error but compiling dgemmtest gives
-------------------------------------------------------------------------------------------------
[pratik@localhost vasp.4.6]$ make dgemmtest
./preprocess <dgemmtest.F | /usr/bin/cpp -P -C -traditional >dgemmtest.f90 -DMPI -DHOST=\"LinuxIFC\" -DIFC -Dkind8 -DNGZhalf -DCACHE_SIZE=4000 -DPGF90 -Davoidalloc -DMPI_BLOCK=500
/opt/MPI/lam-7.1.4/lam/bin/mpif90 -FR -lowercase -assume byterecl -O1 -xW -tpp7 -c dgemmtest.f90
ifort: command line remark #10148: option '-tp' not supported
/opt/MPI/lam-7.1.4/lam/bin/mpif90 -o dgemmtest -L/opt/intel/fce/10.1.012/lib -lsvml dgemmtest.o random.o base.o -L../vasp.4.lib -ldmy ../vasp.4.lib/linpack_double.o ../vasp.4.lib/lapack_double.o -L/opt/intel/mkl/10.0.1.014/lib/em64t/ -lmkl_em64t -lguide -lpthread
dgemmtest.o: In function `MAIN__':
dgemmtest.f90:(.text+0x49a): undefined reference to `m_exit_'
random.o: In function `rmarin_':
random.f90:(.text+0xb4): undefined reference to `m_exit_'
/opt/MPI/lam-7.1.4/lam/bin/mpif90: No such file or directory
make: *** [dgemmtest] Error 1
----------------------------------------------------------------------------------------------------
and compiling ffttest gives
-----------------------------------------------------------------------------------------------------------
[pratik@localhost vasp.4.6]$ make ffttest
/opt/MPI/lam-7.1.4/lam/bin/mpif90 -o ffttest -L/opt/intel/fce/10.1.012/lib -lsvml ffttest.o mpi.o mgrid.o random.o smart_allocate.o base.o fftmpi.o fftmpi_map.o fft3dlib.o /opt/intel/mkl/10.0.1.014/lib/em64t/libfftw3xf_intel.a -L../vasp.4.lib -ldmy ../vasp.4.lib/linpack_double.o ../vasp.4.lib/lapack_double.o -L/opt/intel/mkl/10.0.1.014/lib/em64t/ -lmkl_em64t -lguide -lpthread
fftmpi_map.o: In function `mapset_':
fftmpi_map.f90:(.text+0x1977): undefined reference to `sort_redis_asc_'
fftmpi_map.f90:(.text+0x1c2e): undefined reference to `sort_redis_asc_'
/opt/MPI/lam-7.1.4/lam/bin/mpif90: No such file or directory
make: *** [ffttest] Error 1
---------------------------------------------------------------------------------------------------------
I guess this is due to the format of mpif.h file. To convert it from F77 to f90 I am not able to find "convert" utility in ~/src/vasp.4.6/ or on ftp server files.
Thank you

Pratik Dhuvad
MSU Baroda, India

convert utility not found- ffttest fail

Posted: Fri Sep 12, 2008 11:04 am
by admin
you do not need ffttest and dgemmtest to run vasp, these executale are just for performance test of the fft and the DGEMM (BLAS).

convert utility not found- ffttest fail

Posted: Thu Jan 01, 2009 4:53 am
by shiv akarsh
the convert utility is placed in vasp4 folder in the earlier VASP versions like 4.4.2