-Og
Optimize debugging experience. -Og enables optimizations that do not interfere with debugging. It should be the optimization level of choice for the standard edit-compile-debug cycle, offering a reasonable level of optimization while maintaining fast compilation and a good debugging experience.
Advantages:
Disadvantages:
[1] https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#index-Ofast-903