Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

General Optimization Question

philip-cobb7
Beginner
565 Views
After reading through the users guide on optimization for the Intel Fortran compiler for Linux, I had a question. Is the optimization mainly for just compiling the code, or for actually speeding up the running of the code once compiled? I have been working on this, and I haven't really noticed any major difference in speed of running code with or without different optimizations. Am I doing something wrong? Is there a general technique that I should be using to get my code to run the fastest possible? Any help would be great. Thanks.
0 Kudos
1 Reply
Steven_L_Intel1
Employee
565 Views
The goal of optimization is to make your program run faster. While we'd like the compilation to be fast too, that's not something you control with optimization switches.

It may be that your application is not CPU or memory-bound, which limits the effect of optimization. You can use code profiling tools such as prof, or if you have a Windows PC available, you can use Intel's VTune performance analyzer with the data collector run on Linux.

If your application is waiting for disk I/O to complete, or is being limited by memory throughput, there may not be much a compiler can do to help you. A good analyzer will tell you where your program is spending its time.

Steve
0 Kudos
Reply