On Thu, Aug 18, 2022 at 7:14 AM Masahiro Yamada <masahiroy@xxxxxxxxxx> wrote: > > -g1 is only possible via DEBUG_INFO_LEVEL, but > presumably it is not your main interest > (and not sure if there is anybody interested) > because the main motivation for your v1 > is to generate macro debug data. I tested the build process with -g1 and it turned out to generate an image that is 20% lesser in size. This is indeed not really my use-case, but are you sure it might not be helpful in general? The reason to add DEBUG_INFO_LEVEL was also motivated by the GCC11+/Clang12+ behavior of -gsplit-dwarf to provide an orthogonal debug level config. "The later -g<level> wins" behavior in turns works identically for both older and newer compiler versions so such an implementation provides version independent build behavior. Testing on gcc-11, -gdwarf-<level>/-gdwarf still implies -g2. It seemed a clearer way to me to explicitly set a debug level that just wins instead of relying on implicits. Regards Dmitrii