[Lldb-commits] [PATCH] D51208: [DWARF] Fix dwarf5-index-is-used.cpp

David Blaikie via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Aug 27 10:52:16 PDT 2018


dblaikie added a comment.

>> But if LLDB has different performance characteristics, or the default should be different for other reasons - I'm fine with that. I think I left it on for Apple so as not to mess with their stuff because of the MachO/dsym sort of thing that's a bit different from the environments I'm looking at.
> 
> These are the numbers from my llvm-dev email in June:
> 
>> setting a breakpoint on a non-existing function without the use of
>>  accelerator tables:
>>  real    0m5.554s
>>  user    0m43.764s
>>  sys     0m6.748s
>> 
>> setting a breakpoint on a non-existing function with accelerator tables:
>>  real    0m3.517s
>>  user    0m3.136s
>>  sys     0m0.376s
> 
> This is an extreme case,

What was being tested here? Is it a realistic case (ie: not a pathalogical case with an absurd number of symbols, etc)? Using ELF? Fission or not?

How's it compare to GDB performance, I wonder? Perhaps LLDB hasn't been optimized for the non-indexed case and could be - though that'd still potentially motivate turning on indexes by default for LLDB until someone has a motivation to do any non-indexed performance tuning/improvements.

> because practically the only thing we are doing is building the symbol index, but it's nice for demonstrating the amount of work that lldb needs to do without it. In practice, the ratio will not be this huge most of the time, because we will usually find some matches, and then will have to do some extra work, which will add a constant overhead to both sides. However, this means that the no-accel case will take even longer. I am not sure how this compares to gdb numbers, but I think the difference here is significant.
> 
> Also, I am pretty sure the Apple folks, who afaik are in the process of switching to debug_names, will want to have them on by default for their targets (ping @aprantl, @JDevlieghere). I think the cleanest way (and one that best reflects the reality) to achieve that would be to have `-glldb` imply `-gpubnames`. As for whether we should emit debug_names for DWARF 5 by default (-gdwarf-5 => -gpubnames) is a more tricky question, and I don't have a clear opinion on that (however, @probinson might).
> 
> (In either case, I agree that there are circumstances in which having debug_names is not beneficial, so having a flag to control them is a good idea).

*nod* Happy if you want to (or I can) have clang set pubnames on by default when tuning for LLDB, while allowing -gno-pubnames to turn them off. (& maybe we should have another alias for that flag, since debug_names isn't "pubnames", but that's pretty low-priority)


Repository:
  rLLDB LLDB

https://reviews.llvm.org/D51208





More information about the lldb-commits mailing list