[llvm] [ADT] Add standalone_debug attribute to SmallVectorBase (PR #82527)

Alexander Richardson via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 21 14:37:41 PST 2024


arichardson wrote:

> You can speed up gdb startup time (for clang, for me, it goes from 30s to 3s) with gdb-index. Add -ggnu-pubbames to the compiler flags and -Wl,--gdb-index to the linker flags (using gold or lld I think both support the index)

Fortunately, this flag is already added automatically for LLVM_USE_SPLIT_DWARF builds thanks to https://github.com/llvm/llvm-project/commit/b1b68b4c0190b7fc7f0ebe823277966056b39494

I learned about this incredibly useful flag when I tried using GDB in an emulated QEMU instance where it went from multiple minutes of loading to < 30 seconds.

I'll go ahead and close this PR and open one that adds a warning to the pretty printers instead.

https://github.com/llvm/llvm-project/pull/82527


More information about the llvm-commits mailing list