[all-commits] [llvm/llvm-project] 16711b: [lld][ELF] Add --debug-names to create merged .de...

cmtice via All-commits all-commits at lists.llvm.org
Thu Apr 18 14:41:36 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 16711b431b843dd2143d38fdf6b0591dfb1783e0
      https://github.com/llvm/llvm-project/commit/16711b431b843dd2143d38fdf6b0591dfb1783e0
  Author: cmtice <cmtice at google.com>
  Date:   2024-04-18 (Thu, 18 Apr 2024)

  Changed paths:
    M lld/ELF/Config.h
    M lld/ELF/DWARF.cpp
    M lld/ELF/DWARF.h
    M lld/ELF/Driver.cpp
    M lld/ELF/Options.td
    M lld/ELF/SyntheticSections.cpp
    M lld/ELF/SyntheticSections.h
    M lld/ELF/Writer.cpp
    M lld/docs/ReleaseNotes.rst
    M lld/docs/ld.lld.1
    A lld/test/ELF/Inputs/debug-names-a.s
    A lld/test/ELF/Inputs/debug-names-b.s
    A lld/test/ELF/debug-names-bad.s
    A lld/test/ELF/debug-names-die-offset-form-flag-present.s
    A lld/test/ELF/debug-names-different-aug-string.s
    A lld/test/ELF/debug-names-dwarf64.s
    A lld/test/ELF/debug-names-missing-parent.s
    A lld/test/ELF/debug-names-multi-cus.s
    A lld/test/ELF/debug-names-nonames.s
    A lld/test/ELF/debug-names-parent-idx.s
    A lld/test/ELF/debug-names-type-units.s
    A lld/test/ELF/debug-names.s
    M lld/test/ELF/driver.test
    A lld/test/ELF/ppc32-debug-names.s

  Log Message:
  -----------
  [lld][ELF]  Add --debug-names to create merged .debug_names. (#86508)

`clang -g -gpubnames` (with optional -gsplit-dwarf) creates the
`.debug_names` section ("per-CU" index). By default lld concatenates
input `.debug_names` sections into an output `.debug_names` section.
LLDB can consume the concatenated section but the lookup performance is
not good.

This patch adds --debug-names to create a per-module index by combining
the per-CU indexes into a single index that covers the entire load
module. The produced `.debug_names` is a replacement for `.gdb_index`.

Type units (-fdebug-types-section) are not handled yet.

Co-authored-by: Fangrui Song <i at maskray.me>

---------

Co-authored-by: Fangrui Song <i at maskray.me>



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list