This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GCC 4.8 and -Og

Hi All,

I read the relase notes on GCC 4.8
( and -Og caught my eye  (the
bulleted item is below).

>From the description, it looks like the switch addresses three issues:
(1) compilation time, (2) 'debugging experience', and (3) runtime
performance. I'm not clear on the debugging experience.

I normally use a debug configuration of "-O0 -g3". -g3 ensure things
like #defines and symbolic constant are available if needed.

What "n" does -Og correspond to for -O and -g (i.e., -O1, -O2; -g2, -g3)?

Is there any interaction with -ggdb? As I understand it, -ggdb is
currently not used for anything even though the man pages tell us its
for GDB extensions.

Is -Og -g3 a valid combination to get the benefits of -Og with maximum
symbol support? Is it even needed?


"A new general optimization level, -Og, has been introduced. It
addresses the need for fast compilation and a superior debugging
experience while providing a reasonable level of runtime performance.
Overall experience for development should be better than the default
optimization level -O0."

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]