This paper describes coding techniques that may improve optimization of your programs at level 2 and recommends using compiler options to help you get the best performance from your application code.
Hi Tim,
In order to get some assurance that your code is language standards compliant, you could compile with -qinfo=lan:por option. This should generate informational messages that your code complies with the language level specified (lan) and that you are not using non-portable constructs (por).
However, in order to conclusively determine that your code is standards compliant, you can compile with:
* -qlanglvl=stdc89 for C89 standard compliance (C only)
* -qlanglvl=stdc99 for C99 standard compliance (C only)
* -qlanglvl=strict98 for C++ standard compliance (C++ only)
This will generate warnings and/or errors in the case where language standards compliance is broken. If your code compiles clean, you can be assured that it is standards compliant.

Hi,
I found this to be a very good document describing the optimization features of the IBM xlC/C++ compiler.
It would be nice if the document contained a summary table of the compiler options and their possible values along with a short description of their effect. This could then be used as a quick-reference by those people who are using the optimization capabilities.
I had one question:
The article mentions several times the importance of making sure that the source code is "compliant ... with the language standard". Is there a compile option that can be used to point out areas of the code that are NOT compliant with the language standard?
Thanks,
Tim Hahn