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

Optimisations for Pentium 4 and Pentium M simulataneously?

schapman
Einsteiger
966Aufrufe
Hello,
We would like to optimise our application for both Pentium 4 and pentium M simulataneously, while also having a generic version to run on other processors. The optimisation tutorial seems to imply that the compiler can generate three optimisation paths, but we can figure out how to set the parameters. When we select properties for the project, we are allowed to choose one processor type only. Is there a way to optimise for more than one processor type at the same time, and if so, how?

Thanks
Steve
0 Kudos
7 Antworten
TimP
Geehrter Beitragender III
966Aufrufe
Did you try setting an option such as -QaWB ?
schapman
Einsteiger
966Aufrufe
The problem is that the GUI only allows you to set one type of optimisation at a time: /QaxN, etc. The doco and command line allow multiple choices, but I can't figure out how to set them through the GUI. I would like to set the equivalent of /QaxNP if I can figure out how to do that.

Steve
Steven_L_Intel1
Mitarbeiter
966Aufrufe
You're right that the Visual Studio IDE doesn't provide a GUI setting for more than one, but you can add /QaxNB manually on the Command Line property page under Additional Options.

You may find that a simple /QaxW or /QaxN is sufficient, and I would recommend using N instead of W as if you use the auto-CPU dispatch and run on non-Intel processors, you'll always get the generic path.
schapman
Einsteiger
966Aufrufe
Steve,
If I do use /QaxW, will I get the W case to execute on Opterons? OOur most important customer has a 52 machine farm with that CPU.

Thanks
Steve
Steven_L_Intel1
Mitarbeiter
966Aufrufe
If you use /QaxW, you'll get generic code for Opteron. Sounds to me as if you want /QxW instead. That will run well on Pentium 4 and Opteron, with the disadvantage that processors that don't support the P4 instruction set won't work.
schapman
Einsteiger
966Aufrufe
So the only way to force optimisation for the Opteron is to NOT include the generic version as well? That means we must maintain two code bases for any customers who have something that is Pentium III on their site.

Will the /QxW run on Pentium M, Pentium 4, and Opteron all equally well?
Steven_L_Intel1
Mitarbeiter
966Aufrufe
If your application is to run on Pentium M, Pentium 4 and Opteron, use /QxW. You'll get very good performance on all three processor kinds.

If you are also throwing Pentium III into the mix, that's a different story. You could use /QxK and give up some performance on the newer processors. I'd suggest trying it both ways and see if the difference is noticeable. It may not be.

But yes, using auto-CPU dispatch will cause Opteron to take the generic path.
Antworten