Question:
The uniqueness of the watershed I am working on led me to make a minor modification to the SWAT source code.The modification doesn't add any calculations, but, when I compile it with the new Intel Visual Fortran Compiler 11.1, it actually takes slightly longer to run on my computer using Win32 architecture 60 seconds instead of 56 seconds. I can live with that, but I'm thinking the new compiler should actual ly be able to shave off some time.Worse still, when I compile with the new Fortran 11.1 compiler on a 64 bit desktop, it runs MUCH slower on that desktop (over 2 minutes), though there should be a way,I think, for it to run faster.Run times are important to me because I'm doing extensive uncertainty analysis.Anyone have any ideas?Itried to follow a handout from a SWAT workshop on compiling using Fortran 6.6C, but the software has changed so much since then.
Answer:
From my limited understanding attempts at compiling with the Intel compiler, with lots of trial and error, here are a few of my conclusions:
(1) the "release" set of compiler options results in very fast code, andhydrology seemed OK, but sediment and maybe other water quality ariables were corrupted in some of the output files (floating point over flowerrors).The Reach output was corrupt, but I think the HRU and Sub output might be OK.
(2) the "full debug" set of compiler options produced very big and slow code
(3) the run time option to check array and string bounds seems to be the critical factor that makes the code big and slow.Try turning this off.
(4) the "library" option for "debug multithreaded" seems to be the critical factor in avoiding the overflow errors I noted above.So if I'm just running for hydrology, I use an executable created with the"release" compiler options.If I'm looking at sediment and nutrients, I recompile, starting with the "release" version but then add step (4).
Answer:
From my limited understanding attempts at compiling with the Intel compiler, with lots of trial and error, here are a few of my conclusions:
(1) the "release" set of compiler options results in very fast code, andhydrology seemed OK, but sediment and maybe other water quality ariables were corrupted in some of the output files (floating point over flowerrors).The Reach output was corrupt, but I think the HRU and Sub output might be OK.
(2) the "full debug" set of compiler options produced very big and slow code
(3) the run time option to check array and string bounds seems to be the critical factor that makes the code big and slow.Try turning this off.
(4) the "library" option for "debug multithreaded" seems to be the critical factor in avoiding the overflow errors I noted above.So if I'm just running for hydrology, I use an executable created with the"release" compiler options.If I'm looking at sediment and nutrients, I recompile, starting with the "release" version but then add step (4).
本文探讨了针对SWAT源代码进行编译时遇到的问题,包括使用Intel Visual Fortran Compiler 11.1后的运行速度变化,以及如何通过调整编译选项来优化程序性能,特别是针对水文学模拟的需求。

被折叠的 条评论
为什么被折叠?



