clayborg wrote:

We already have bits that know if the size is synthesize in 
`lldb_private::Symbol::m_size_is_synthesized` and we have a bit that tracks is 
the size is valid with `lldb_private::Symbol::m_size_is_valid`. We could 
accomplish this `size on demand` feature by letting clients subclass a special 
class that does this and is created and registered with the `Symtab` when it is 
created. Then any accesses to the `Symtab` class can be taught to check if a 
symbol's size is valid or not, and if it isn't check if the size can be 
calculated, and if so, call through to the new size helper class to complete 
the size of any symbols. ELF symbol tables would just not register a `size 
completion class`, but Mach-O would.

https://github.com/llvm/llvm-project/pull/106791
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to