[PATCH] D74169: [WIP][LLD][ELF][DebugInfo] Remove obsolete debug info.

Alexey Lapshin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 10 04:17:10 PDT 2020


avl added a comment.

> Might be worth comparing with -gdb-index too (though not sure if gdb-index will be immediately compatible with the DWARF aware linking, so a difficult comparison - but even comparing "gdb-index without DWARF-aware linking V DWARF-aware linking without gdb-index", etc)

here are the results for clang binary:

  -------------------------------------------------------------
  |     Options    | Run-time, sec | Used Memory, kb |  Size  |
  -------------------------------------------------------------
  |                |     35.58     |     9403596     |  1,4G  |
  -------------------------------------------------------------
  |  gc-debuginfo  |    109.15     |    14275444     |  783M  |
  -------------------------------------------------------------
  |  gc-debuginfo  |    130.63     |    14394700     |  797M  |
  |   gdb-index    |               |                 |        |
  -------------------------------------------------------------
  |   gdb-index    |     52.88     |     9524976     |  1.5G  | 
  -------------------------------------------------------------

I did not check whether gdb-index is compatible with DWARF aware linking output.

There probably exists the room for optimization of gdb-index(related to the strategy of DWARF context creation). 
As it was mentioned in  https://reviews.llvm.org/D74773#1920751 simple caching of DWARF context results in an 8% performance increase and 20% memory usage increase. 
It is probably worth implementing some smart strategy(reference counting?) that will keep DWARF context while there are users of it and release it when it is not expected to be used(so that it does not hold all DWARF contexts forever).


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D74169/new/

https://reviews.llvm.org/D74169





More information about the llvm-commits mailing list