[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 3 11:21:44 PDT 2020
avl added a comment.
Size/Performance/Memory results:
lld binary size with this patch(SHARED_LIBS=OFF) - 49925kb.
lld binary size without this patch(SHARED_LIBS=OFF) - 49699kb.
Performance results for building whole LLVM:
--------------------------------------------------------------------------
| | CL options | LLVM bin size | LLVM build time |
--------------------------------------------------------------------------
| A | (default set of options*) | 100.0%(18.0GB)| 100.0%(75m15s) |
| | | | |
| B | A +gc-debuginfo(**) +NoOdr=false| 54%(9,7GB) | 124.0%(93m33s) |
| | | | |
| C | A +gc-debuginfo +NoOdr=false | 43%(7,7GB) | 107.0%(80m26s) |
| | +fdebug-types-section(***) | | |
--------------------------------------------------------------------------
Performance results of lld for building single clang binary:
---------------------------------------------------------------------------------
| | CL options | Clang size | link time | run-time memory |
---------------------------------------------------------------------------------
| A | (default set of options*) | 100.0%(1,4GB)| 100%(49s) | (100%)9.3GB |
| | | | | |
| B | A +gc-debuginfo +NoOdr=false | 56.0%(0.78GB)| 296%(145s)| (153%)14.2GB |
| | | | | |
| C | A +gc-debuginfo +NoOdr=true | 86.0%(1.2GB) | 380%(186s)| (161%)15GB |
| | | | | |
| D | A +gc-debuginfo +NoOdr=false | 42.0%(0.59GB)| 133%(65s) | (113%)10.5GB |
| | +fdebug-types-section(***) | | | |
---------------------------------------------------------------------------------
(*)
LLVM_TARGETS_TO_BUILD=X86;AArch64
LLVM_ENABLE_PROJECTS=clang;lld
LLVM_ENABLE_LLD=ON
CMAKE_CXX_FLAGS=--ffunction-sections
CMAKE_C_FLAGS=--ffunction-sections
CMAKE_CXX_FLAGS_DEBUG=-g
CMAKE_C_FLAGS_DEBUG=-g
CMAKE_EXE_LINKER_FLAGS=--Wl,--gc-sections
CMAKE_MODULE_LINKER_FLAGS=-Wl,--gc-sections
CMAKE_SHARED_LINKER_FLAGS=-Wl,--gc-sections
(**)
- gc-debuginfo - removes obsolete debug info. implemented by this patch.
- NoOdr - mode of DWARFLinker which switches on/off types deduplication. there is no command line option to switch it on/off.
- fdebug-types-section - deduplicates types using comdat sections.
(***) fdebug-types-section is not supported by dsymutil/DWARFLinker.
Thus presented results do not show real data.
But these numbers could be taken as an estimation for future results
when DWARF5/-fdebug-types-section would be supported by dsymutil/DWARFLinker.
(****) HW configuration:
OS Ubuntu 18.04
CPU Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz
RAM 32018 MiB
Storage SSD
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D74169/new/
https://reviews.llvm.org/D74169
More information about the llvm-commits
mailing list