Page MenuHomePhabricator

Document `LLVM_USE_SPLIT_DWARF` option
Needs ReviewPublic

Authored by beanz on Oct 6 2019, 2:17 PM.

Details

Reviewers
dblaikie
Summary

This patch adds a documentation note about the LLVM_USE_SPLIT_DWARF CMake option which is useful to reduce linker memory usage.

Event Timeline

beanz created this revision.Oct 6 2019, 2:17 PM
Herald added a project: Restricted Project. · View Herald TranscriptOct 6 2019, 2:17 PM

FWIW, the current support is incomplete - if you just turn on -gsplit-dwarf, gdb may misbehave owing to a lack of index. (you'd need to add -Wl,-gdb-index to CMAKE_*_LINKER_FLAGS)

Arguably we could/should fix LLVM itself to pass that flag when using -gsplit-dwarf while tuning for gdb and/or improve the LLVM CMake build to add the flag.