[Lldb-commits] [PATCH] D26093: Limit LLDB_EXPORT_ALL_SYMBOLS to additionally export only the lldb_private namespace symbols

Todd Fiala via lldb-commits lldb-commits at lists.llvm.org
Fri Oct 28 13:43:27 PDT 2016

tfiala added a comment.

In https://reviews.llvm.org/D26093#582395, @labath wrote:

> I am a bit surprised that this fixes the problem. I would have expected that the problem would occur in case when we *do* restrict exports,

This matches my expectations.  When I was using the flag the exported all symbols indiscriminately from liblldb.so, it meant that the llvm symbols for the copy inside liblldb.so were public and known.  That public element allows the dynamic linker to coalesce the data storage locations with the ones for the llvm in lldb-mi.  Hiding them (as per the normal case, when we only export the 'lldb' public namespace) prevents the dynamic linker from doing the coalesce.

as in that case, it is much easier to pull in copies of stuff twice. I wonder if in this case we could actually avoid having two copies of llvm.

> What would happen if you just remove the call to llvm_config in lldb-mi's CMakeLists.txt. Will you get some unresolved symbols?
> Adding @beanz, in case he has some ideas.


More information about the lldb-commits mailing list