public inbox for dwz@sourceware.org
 help / color / mirror / Atom feed
* [Bug default/27440] New: [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup
@ 2021-02-19 11:43 mark at klomp dot org
  2021-02-19 15:42 ` [Bug default/27440] " jakub at redhat dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: mark at klomp dot org @ 2021-02-19 11:43 UTC (permalink / raw)
  To: dwz

https://sourceware.org/bugzilla/show_bug.cgi?id=27440

            Bug ID: 27440
           Summary: [dwz, dwarf5] Add --dwarf-5 flag to generate
                    .debug_sup, ref_sup and strp_sup
           Product: dwz
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: default
          Assignee: nobody at sourceware dot org
          Reporter: mark at klomp dot org
                CC: dwz at sourceware dot org
            Blocks: 24726
  Target Milestone: ---

Currently the dwz multi-files are really DWARF4 + GNU extensions. Since the
format and references were formalized in the DWARF5 spec as DWARF Supplementary
Object Files (DWARF5 section 7.3.6) it would be nice to have a way to generate
this format with a --dwarf-5 flag:

- Use DW_FORM_ref_sup[48] and DW_FORM_strp_sup instead of
  DW_FORM_GNU_ref_alt and DW_FORM_GNU_strp_alt

- Generate .debug_sup section (standardized variant of .gnu_debugaltlink)


Referenced Bugs:

https://sourceware.org/bugzilla/show_bug.cgi?id=24726
[Bug 24726] [dwz] Support DWARF5
-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug default/27440] [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup
  2021-02-19 11:43 [Bug default/27440] New: [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup mark at klomp dot org
@ 2021-02-19 15:42 ` jakub at redhat dot com
  2021-02-21  0:09 ` tromey at sourceware dot org
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at redhat dot com @ 2021-02-19 15:42 UTC (permalink / raw)
  To: dwz

https://sourceware.org/bugzilla/show_bug.cgi?id=27440

Jakub Jelinek <jakub at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                URL|                            |https://sourceware.org/pipe
                   |                            |rmail/dwz/2021q1/000930.htm
                   |                            |l
                 CC|                            |jakub at redhat dot com

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug default/27440] [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup
  2021-02-19 11:43 [Bug default/27440] New: [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup mark at klomp dot org
  2021-02-19 15:42 ` [Bug default/27440] " jakub at redhat dot com
@ 2021-02-21  0:09 ` tromey at sourceware dot org
  2021-02-21  0:29 ` jakub at redhat dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: tromey at sourceware dot org @ 2021-02-21  0:09 UTC (permalink / raw)
  To: dwz

https://sourceware.org/bugzilla/show_bug.cgi?id=27440

Tom Tromey <tromey at sourceware dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |tromey at sourceware dot org

--- Comment #1 from Tom Tromey <tromey at sourceware dot org> ---
I found out today that gdb doesn't support these forms.
It also doesn't know about .debug_sup.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug default/27440] [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup
  2021-02-19 11:43 [Bug default/27440] New: [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup mark at klomp dot org
  2021-02-19 15:42 ` [Bug default/27440] " jakub at redhat dot com
  2021-02-21  0:09 ` tromey at sourceware dot org
@ 2021-02-21  0:29 ` jakub at redhat dot com
  2021-02-21 23:19 ` tromey at sourceware dot org
  2021-02-26 23:26 ` mark at klomp dot org
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at redhat dot com @ 2021-02-21  0:29 UTC (permalink / raw)
  To: dwz

https://sourceware.org/bugzilla/show_bug.cgi?id=27440

--- Comment #2 from Jakub Jelinek <jakub at redhat dot com> ---
I think no consumer does, because nothing was producing that.
Which is why it is produced under non-default switch now, so that consumers can
be adapted and perhaps in 6 months or 12 months we can switch the default (in
that case probably only if there were DWARF 5 CUs present, at least some).

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug default/27440] [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup
  2021-02-19 11:43 [Bug default/27440] New: [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup mark at klomp dot org
                   ` (2 preceding siblings ...)
  2021-02-21  0:29 ` jakub at redhat dot com
@ 2021-02-21 23:19 ` tromey at sourceware dot org
  2021-02-26 23:26 ` mark at klomp dot org
  4 siblings, 0 replies; 6+ messages in thread
From: tromey at sourceware dot org @ 2021-02-21 23:19 UTC (permalink / raw)
  To: dwz

https://sourceware.org/bugzilla/show_bug.cgi?id=27440

--- Comment #3 from Tom Tromey <tromey at sourceware dot org> ---
I sent a gdb patch to handle this.
https://sourceware.org/pipermail/gdb-patches/2021-February/176508.html

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug default/27440] [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup
  2021-02-19 11:43 [Bug default/27440] New: [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup mark at klomp dot org
                   ` (3 preceding siblings ...)
  2021-02-21 23:19 ` tromey at sourceware dot org
@ 2021-02-26 23:26 ` mark at klomp dot org
  4 siblings, 0 replies; 6+ messages in thread
From: mark at klomp dot org @ 2021-02-26 23:26 UTC (permalink / raw)
  To: dwz

https://sourceware.org/bugzilla/show_bug.cgi?id=27440

Mark Wielaard <mark at klomp dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #4 from Mark Wielaard <mark at klomp dot org> ---
commit 4e55da9f7700dda5936c7a486651674dbc782a7e
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Sat Feb 20 10:47:53 2021 +0100

    PR27440 - add --dwarf-5 support

    This adds --dwarf-5 support, so that dwz can emit standard DWARF 5
    Supplementary object files with .debug_sup section and debug info referring
    to those with .debug_sup section instead of .gnu.debugaltlink and standard
    DWARF 5 DW_FORM_*sup instead of the DW_FORM_GNU_*alt forms.

            * dwz.1: Document --dwarf-5 and -5 options.
            * dwz.c (enum debug_section_kind): Add DEBUG_SUP.
            (debug_sections): Add .debug_sup section entry.
            (multifile_name, multifile_relative): Adjust comment.
            (dwarf_5): New variable.
            (note_strp_offset2): Adjust function comment.  If dwarf_5, return
            DW_FORM_strp_sup instead of DW_FORM_GNU_strp_alt.
            (macro_eq, read_macro, optimize_write_macro, handle_macro): Use
            standard DWARF 5 DW_MACRO_* names instead of their DW_MACRO_GNU_*
            aliases.
            (write_macro): Likewise.  Handle DW_FORM_strp_sup.
            (build_abbrevs_for_die): If dwarf_5, use DW_FORM_ref_sup4 instead
of
            DW_FORM_GNU_ref_alt.
            (write_unit_die): Handle DW_FORM_strp_sup.
            (write_die): Handle DW_FORM_ref_sup4 and DW_FORM_strp_sup.
            (read_dwarf): Fail if .debug_sup section is present, unless
            rd_multifile in dwarf_5 mode.
            (dwz): Write .debug_sup section instead of .gnu.debugaltlink if
            dwarf_5.
            (optimize_multifile): Write .debug_sup section instead of
            .note.gnu.build-id.
            (dwz_options): Add --dwarf-5 and -5 options.
            (dwz_multi_file_options_help): Mention .debug_sup section in -M
            description.  Add --dwarf-5 description.
            (main): Handle --dwarf-5 and -5 options.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-02-26 23:26 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-19 11:43 [Bug default/27440] New: [dwz, dwarf5] Add --dwarf-5 flag to generate .debug_sup, ref_sup and strp_sup mark at klomp dot org
2021-02-19 15:42 ` [Bug default/27440] " jakub at redhat dot com
2021-02-21  0:09 ` tromey at sourceware dot org
2021-02-21  0:29 ` jakub at redhat dot com
2021-02-21 23:19 ` tromey at sourceware dot org
2021-02-26 23:26 ` mark at klomp dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).