24小时热门版块排行榜    

北京石油化工学院2026年研究生招生接收调剂公告
查看: 360  |  回复: 2
【奖励】 本帖被评价1次,作者灯塔守望者增加金币 0.5
当前主题已经存档。

[资源] 【分享】Building VASP with MKL

Building VASP

Build FFTW wrapper library for Intel® MKL
Change directory to /interfaces/fftw3xf.
Assuming default installation-- $cd /opt/intel/mkl/10.0.2.018/interfaces/fftw3xfBuild the fftw 3.x Fortran wrapper library for Intel® 64 (previously known as em64t) platform using the Intel compilers. $make libem64t compiler=intelThis will create the fftw wrapper library "libfftw3xf_intel.a" in lib/em64t directory of your Intel® MKL installation.



Build libdmy.a
Change directory to vasp.x.x.lib.
Run the following command from vasp.x.x.lib, using the Makefile for linux using the Intel compiler.
#make -f makefile.linux_ifc_P4After a successful compilation, libdmy.a will be built in the same directory.


Build VASP
Change directory to vasp.x.x.
Edit the makefile.linux_ifc_P4 to link with Intel® MKL libraries.
Go to the section where BLAS, LAPACK and FFT libraries are specified and change as below, assuming the default installation /opt/intel/mkl/10.0.2.018 for MKL 10.0 update 2.
BLAS=-L/opt/intel/mkl/10.0.2.018/lib/em64t -lmkl_intel_lp64 -lmkl_blacs_lp64 -lmkl_intel_thread -lmkl_core -liomp5 -lpthread
LAPACK=-L/opt/intel/mkl/10.0.2.018/lib/em64t -lmkl_intel_lp64 -lmkl_blacs_lp64 -lmkl_intel_thread -lmkl_core -liomp5 -lpthread
FFT3D= fftmpiw.o fftmpi_map.o fft3dlib.o /opt/intel/mkl/10.0.2.018/lib/em64t /libfftw3xf_intel.aModify Fortran compiler flags line to include fftw3.f from Intel® MKL include directory as below:
FFLAGS= -I/opt/intel/mkl/10.0.2.018/include/fftw -FR -lower_caseThis will eliminate compilation errors pertaining to "cannot open include file `fftw3.f' when Intel® MKL FFT is used rather than VASP's own FFTs.
To use Intel® MKL ScaLAPACK, modify additional options for CPP for parallel version adding -DscaLAPACK to the CPP line and specify Intel® MKL ScaLAPACK as below:
SCA=/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_scalapack_lp64.a /opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_blacs_intelmpi_lp64.a
To use Intel® MPI specify Fortran compiler as FC=mpiifort.
Run the following command to build vasp:
$make -f makefile.linux_ifc_P4This will create the VASP executable in the current directory.


Step 5 - Running VASP
Run vasp by executing the following command with your workloads:
$mpirun -n 4 ./vasp

Appendix A - Performance Results

Below are VASP benchmark results for HG. VASP version is 4.6.28 on an Intel® Xeon 5400 series Harpertown machine.

Two Quad-core Xeon EM64T (harpertown) 2.83GHz CPUs
2 x 6M Cache
16G Bytes Memory
1333MHz FSB
OS:

RedHat Enterprise 4 U4
Libraries used:

Intel® MKL 9.1.023 (including BLAS, LAPACK & FFT which are be used in VASP)
Intel® MPI 3.1
Compiler to use:

Intel 10.1 C/C++ complier for EM64T
Intel 10.1 Fortran complier for EM64T
Running time (seconds)
Process Number Baseline program Tuned program with MKL
1 81.84 70.96
2 42.80 35.01
4 29.89 25.84
8 19.35 17.55



Appendix B - Known Issues and Limitations

When the Intel® MKL FFT is used instead of VASP’s own implementation of FFT, it will give compilation errors similar to these:

fortcom: Error: fftw3d.f90, line 501: Cannot open include file 'fftw3.f'
include 'fftw3.f'
---------------^
fortcom: Error: fftw3d.f90, line 510: This name does not have a type, and must have an explicit type. [FFTW_FORWARD]
FFTW_FORWARD, FFTW_ESTIMATE)To eliminate the above errors, do one of the below mentioned workarounds.

Copy fftw3.f from /Intel® MKL include/fftw to the vasp.x.x directory.
$cp /include/fftw3.f /vasp.4.6OR

Modify makefile to include fftw3.f from Intel® MKL in the FFLAGS line:
FFLAGS= -I//include/fftw


内容来源于http://software.intel.com/en-us/ ... g-intel-mkl-in-vasp

[ Last edited by mingdong on 2009-9-14 at 16:57 ]
回复此楼
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

superest

金虫 (小有名气)


★★★ 三星级,支持鼓励

这个ifort 10.1不是有错误么?跑bench Hg,结果对么?
2楼2008-11-17 21:56:49
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

realac

铜虫 (小有名气)


hoho,ifort还是用9.1的,10.1好像编译vasp还是有问题
3楼2008-11-18 07:30:45
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 灯塔守望者 的主题更新
☆ 无星级 ★ 一星级 ★★★ 三星级 ★★★★★ 五星级
普通表情 高级回复 (可上传附件)
最具人气热帖推荐 [查看全部] 作者 回/看 最后发表
[考研] 281求调剂 +9 aaawhy 2026-04-03 9/450 2026-04-03 20:29 by zhq0425
[考研] 材料调剂 +7 吴棂颖! 2026-04-03 7/350 2026-04-03 19:47 by 百灵童888
[考研] 生物学求调剂 +3 15064154688 2026-04-03 3/150 2026-04-03 10:28 by macy2011
[考研] 330求调剂 +3 白神呜呼呼 2026-04-02 3/150 2026-04-03 10:15 by 蓝云思雨
[考研] 325分化学调剂 +5 15771691647 2026-04-02 5/250 2026-04-03 09:58 by ChemPharm
[考研] 求调剂 +5 朔朔话 2026-04-02 6/300 2026-04-02 22:02 by barlinike
[考研] 282求调剂 +3 aaa车辆 2026-04-02 3/150 2026-04-02 21:55 by zllcz
[考研] 22408 266求调剂 +3 masss11222 2026-04-02 3/150 2026-04-02 18:11 by 笔落锦州
[考研] 279求调剂 +5 傅文秋 2026-04-02 5/250 2026-04-02 18:10 by 笔落锦州
[考研] 385分 生物学(071000)求调剂 +6 qf626 2026-04-01 6/300 2026-04-02 10:39 by guoweigw
[考研] 省双一流重点一本大学招收调剂 +4 wwwwffffff 2026-03-31 7/350 2026-04-01 15:23 by wwwwffffff
[考研] 086000生物与医药 初试274求调剂 +5 小叮当来了 2026-03-30 6/300 2026-04-01 14:25 by mxj1203
[考研] 085600,321分求调剂 +13 大馋小子 2026-03-31 13/650 2026-04-01 12:35 by chemdavid
[硕博家园] 博一被送出联培感觉不适应怎么办 +3 全村的狗 2026-03-31 3/150 2026-04-01 10:44 by 328838485
[考研] 考研材料工程351分调剂 +5 整个好的 2026-03-31 5/250 2026-04-01 09:36 by topgun2009
[考研] 333求调剂 +4 阿科逸 2026-03-31 4/200 2026-04-01 09:11 by jp9609
[考研] 一志愿中海洋材料357 +4 麦恩莉. 2026-03-30 4/200 2026-03-31 14:35 by 记事本2026
[有机交流] 甲基亚磺磺酸钠和甲基磺酸酯反应机理 10+3 kaobao456 2026-03-29 4/200 2026-03-30 23:16 by nBu锂
[考研] 11408总分309,一志愿东南大学求调剂,不挑专业 +5 天赋带到THU 2026-03-29 6/300 2026-03-30 20:49 by dick_runner
[考研] 一志愿南京航空航天大学材料学硕求调剂 +3 @taotao 2026-03-28 3/150 2026-03-28 10:26 by JourneyLucky
信息提示
请填处理意见