Preparing for Debugging

Use the -g option to direct the compiler to generate code to support symbolic debugging. For example:

prompt>icpc -g prog.cpp

The compiler does not support the generation of debugging information in assemblable files. If you specify the -g option, the resulting object file will contain debugging information, but the assemblable file will not.

Note

The -g option changes the default optimization from -O2 to -O0.