[LLVMdev] [Patch] Clean up DynamicLibrary

Axel Naumann Axel.Naumann at cern.ch
Wed Nov 14 09:21:31 PST 2012


Hi,

Attached patch moves code around; it should not have a functional
effect. It formalizes a few concepts that were spread over several files
before, depending on platform. It removes historical leftovers.

Symbol lookup now happens in three easy phases, on all platforms:
* explicitly provided symbols through AddSymbol()
* shared libraries
* platform provided "special" symbols.

No more "strcmp" for each special symbol; they are collected once in a
StringMap. Unix and Windows are now strictly symmetric: there is a
defined set of routines that a platform has to provide.

Does this make sense? (Note that the actual checkin will remove
SearchForAddressOfSpecialSymbol.cpp; svn diff is not very helpful here...)


We need the ability to determine all shared libraries loaded into a
process; currently that's only available for Windows and not very
explicitly. Is there interest to have this in llvm::DynamicLibrary, or
shall I keep this to ourselves?

Cheers, Axel.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: llvm-dylib-reshuffle.diff
Type: text/x-patch
Size: 20360 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20121114/b7e70fa8/attachment.bin>


More information about the llvm-dev mailing list