https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128668
--- Comment #2 from Yongqiang Tian <yqtian668 at gmail dot com> --- Created attachment 66153 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=66153&action=edit patch ok, thank you for clarifying. Here is my proposed fix: exclude debug and CFI notes from the counter used by `%=`. These are the same note kinds GCC already omits from its final instruction dumps. Each asm still advances the counter, so uniqueness is preserved. This fixes the original example and a case where `-g` introduces CFI notes with `-fno-asynchronous-unwind-tables`. It can also renumber existing `-g0` output when CFI notes are present. The focused tests pass. Does this approach look reasonable? If yes, I can submit the patch after bootstrap.
