What’s the difference between 'gcc -g' and 'gcc -g3'?

According with the documentation:

-glevel

Request debugging information and also use level to specify how  much information. The default level is 2.

Where level 3 means:

Level 3 includes extra information, such as all the macro definitions present in the program. Some debuggers support macro expansion when you use -g3.

Leave a Comment