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 assembly files. If you specify the -g option, the resulting object file will contain debugging information, but the assembly file will not.


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