Showing posts with label FFTW. Show all posts
Showing posts with label FFTW. Show all posts

Friday, February 24, 2017

Compiling Intel FFTW3 and FFTW2 Interface Wrapper Library

FFTW3 wrappers to Intel MKL are delivered both in Intel MKL and as source code which can be compiled to build to build standalone wrapper library with exactly the same functionality. The source code for the wrappers, makefiles are found .....\interfaces\fftw3xc subdirectory in the Intel MKL Directory

Intel FFTW3 Interface Wrapper Library. Do the same for fftw3xc and fftw3xf
# cd $MKLROOT
# cd interfaces/fftw3xc
# make libintel  INSTALL_DIR=$MKLROOT/lib/intel64
Once Compiled, the libraries are kept $MKLROOT/lib/intel64  


Intel FFTW2 Interface Wrapper Library. Do the same for fftw2xc and fftw2xf
# cd $MKLROOT
# cd interfaces/fftw2xc
# make libintel  PRECISION=MKL_DOUBLE
# make libintel  PRECISION=MKL_SINGLE
Once Compiled, the libraries are kept $MKLROOT/lib/intel64

Tuesday, October 15, 2013

Compiling and installing FFTW 3.3.3 with OpenMPI and OpenMP

To Compile FFTW 3.3.3 single precision with OpenMPI, make sure you compile and set your path for Intel and OpenMPI.  

Step 1: Compiling FFTW 3.3.3 (Single Precision) with OpenMPI and OpenMP.
After unpacking FFTW 3.3.3, you may want to use the flags
# ./configure CC=icc 
--enable-float --enable-threads --enable-openmp \
--enable-mpi MPICC=mpicc \
LDFLAGS=-L/usr/local/openmpi/intel/lib CPPFLAGS=-I/usr/local/openmpi/intel/include \ 
--prefix=/usr/local/fftw-3.3.3-single
# make -j8
# make install
Inside /usr/local/fftw-3.3.3-single/lib, you should see at least the files below
libfftw3f.a
libfftw3f_mpi.a
libfftw3f_omp.a
libfftw3f_threads.a
....
....


Step 2: Compiling FFTW 3.3.3 (Double Precision) with OpenMPI and OpenMP
# ./configure CC=icc 
--enable-threads --enable-openmp \
--enable-mpi MPICC=mpicc \
LDFLAGS=-L/usr/local/openmpi/intel/lib CPPFLAGS=-I/usr/local/openmpi/intel/include \ 
--prefix=/usr/local/fftw-3.3.3-single
# make -j8
# make install
Inside /usr/local/fftw-3.3.3-double/lib, you should see at least the files below
libfftw3.a
libfftw3_mpi.a
libfftw3_omp.a
libfftw3_threads.a
....
....

Friday, September 20, 2013

Compile and Build FFTW3 wrapper routines on MKL implementation of FFT

Software like VASP uses calling statements of the FFTW3 which differ to the implementation of FFT in MKL. You will need to compile the wrapper routines for MKL

# cd $MKLROOT/interfaces/fftw3xf
# make
After a successful compilation libfftw3xf_intel.a was created in this directory

The information is taken from Installing VASP

Monday, July 8, 2013

Compiling and installing FFTW 3.3.3

1. FFTW 3.3.3 (Single Precision)
# ./configure --enable-float --enable-threads
# make
# make install
2. FFTW 3.3.3 (Double Precision)
# ./configure --enable threads
# make
# make install
3. Important Note. If you using FFTW with Gromacs, you may want to compile without threading as according to the document at Gromacs Installation Instructions .....On x86 hardware, compile only with --enable-sse2 (regardless of precision) even if your processors can take advantage of AVX extensions. Since GROMACS uses fairly short transform lengths we do not benefit from the FFTW AVX acceleration, and because of memory system performance limitations, it can even degrade GROMACS performance by around 20%...... 3a. FFTW 3.3.3 (Single Precision)
# ./configure --enable-float --enable-sse2 
# make 
# make install
3b. FFTW 3.3.3 (Double Precision)
# ./configure --enable-sse2 
# make 
# make install
References:
  1. FFTW Home Page
  2. Installation of FFTW (http://www.uvm.edu/~smanchu/fftw_installation.html)

Tuesday, September 20, 2011

/.../libfftw3f.a: could not read symbols: Bad value when compiling Gromacs

If you encounter this error like " /.../libfftw3f.a: could not read symbols: Bad value when compiling Gromacs ", it is likely due to that the compilation of FFTW did not enable shared libraries "--enable-shared" . GROMACS seems to require shared libraries extension from FFTW. So do follow the steps listed in
  1. Installing FFTW
  2. Installing Gromacs 4.0.x on CentOS 5.x
you should have a clean compilation

Tuesday, May 18, 2010

Installing Quantum-ESPRESSO with OpenMPI, Intel Compilers and MKL

Do read the Quantum-ESPRESSO website on the requirements required.
Installing the Quantum-Espresso distribution

In this blog entry, I'm compiling Quantum-ESPRESSO with OpenMPI, Intel Compilers and MKL. First thing first, prepare the prerequisites
  1. If you are eligible for the Intel Compiler Free Download. Download the Free Non-Commercial Intel Compiler Download
  2. Compile Intel Compilers with OpenMPI. See Building OpenMPI with Intel Compiler. Make sure your pathing are properly written and sourced.
  3. Install FFTW. For more information, see Installing FFTW 
And now Installing Quantum Espresso
  1. Untar the Quantum Espresso package
    # tar -zxvf espresso-4.1.3.tar.gz
  2. Go to the espresso package directory
    # cd espresso-4.1.3/
    # ./configure
  3. Finall Compile
    # make all
    . You should see a number of *.x in the $ESPRESSO_SOURCE/bin directory.
  4. Make sure you PATH your binaries. For more information, see Installing the Quantum-Espresso distribution