avatar
偶也问一fortran问题# Computation - 科学计算
t*o
1
偶以前用F77编译, 最后文件大小是12MB
最近换成F90, 文件大小一下子变成50多M
然后学校最近好象又升级了一下系统, 现在变成60多M
有些受不了了, 总共也就300M空间 。。。
有什么方法让它减肥吗? 偶用 F90 -c -O3
avatar
j*x
2
interesting, never see a final executable size over 10M.
How many lines of source code do you have? and what is the
complete compiling option used?
The command "strip" usually can shink the file size.

【在 t*****o 的大作中提到】
: 偶以前用F77编译, 最后文件大小是12MB
: 最近换成F90, 文件大小一下子变成50多M
: 然后学校最近好象又升级了一下系统, 现在变成60多M
: 有些受不了了, 总共也就300M空间 。。。
: 有什么方法让它减肥吗? 偶用 F90 -c -O3

avatar
t*n
3
If I use -static option, my executable file could go to 300M.

【在 j*x 的大作中提到】
: interesting, never see a final executable size over 10M.
: How many lines of source code do you have? and what is the
: complete compiling option used?
: The command "strip" usually can shink the file size.

avatar
s*r
4
The compiler will treat almost everything subroutine as inline functions in
Fortran.
-O0 should give smaller executable.
Or you can try f2c and then use a c compiler.

【在 t*****o 的大作中提到】
: 偶以前用F77编译, 最后文件大小是12MB
: 最近换成F90, 文件大小一下子变成50多M
: 然后学校最近好象又升级了一下系统, 现在变成60多M
: 有些受不了了, 总共也就300M空间 。。。
: 有什么方法让它减肥吗? 偶用 F90 -c -O3

avatar
t*o
5

thanks. but use -O0, seems decreasing the computation speed a little

【在 s*****r 的大作中提到】
: The compiler will treat almost everything subroutine as inline functions in
: Fortran.
: -O0 should give smaller executable.
: Or you can try f2c and then use a c compiler.

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。