[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug gas/28149] debug info with wrong file association
From: |
i at maskray dot me |
Subject: |
[Bug gas/28149] debug info with wrong file association |
Date: |
Fri, 17 Sep 2021 08:03:30 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=28149
Fangrui Song <i at maskray dot me> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |i at maskray dot me
--- Comment #5 from Fangrui Song <i at maskray dot me> ---
(In reply to Alan Modra from comment #4)
> I can reproduce the comment #3 behaviour only when using -Wa,-gdwarf or
> similar gas options when using gcc-10. gcc-11 and gcc-12 pass -gdwarf-5 to
> gas. That seems to be the source of these problems, which is that -gdwarf*
> passed to gas means not only to select the DWARF level but also have gas
> generate its own DWARF line info.
>
> So why is gcc passing -gdwarf-5 to gas? That seems quite silly! Can't gas
> figure the dwarf level out itself? Note that current gas decides on dwarf5
> if seeing a .file or .loc specifying file 0.
https://gcc.gnu.org/pipermail/gcc-patches/2020-September/553527.html had the
discussion for the -gdwarf-5 behavior.
gas' detection of DWARF v5 .debug_line was added later:
https://sourceware.org/pipermail/binutils/2021-January/115000.html
If DWARF v6 or a future version ever bumps the line table version again (after
v2->v5), perhaps having a directive is fine. LLVM folks do not object to a
directive (https://reviews.llvm.org/D94882). I agree that passing -gdwarf-* to
gas is probably not very useful.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug gas/28149] debug info with wrong file association, amodra at gmail dot com, 2021/09/16
- [Bug gas/28149] debug info with wrong file association,
i at maskray dot me <=
- [Bug gas/28149] debug info with wrong file association, bernd.edlinger at hotmail dot de, 2021/09/17
- [Bug gas/28149] debug info with wrong file association, cvs-commit at gcc dot gnu.org, 2021/09/17
- [Bug gas/28149] debug info with wrong file association, cvs-commit at gcc dot gnu.org, 2021/09/17
- [Bug gas/28149] debug info with wrong file association, amodra at gmail dot com, 2021/09/17
- [Bug gas/28149] debug info with wrong file association, amodra at gmail dot com, 2021/09/17
- [Bug gas/28149] debug info with wrong file association, cvs-commit at gcc dot gnu.org, 2021/09/19