#include "llvm/Support/DynamicLibrary.h"
#include "llvm-c/Support.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/Config/config.h"
#include "llvm/Support/Mutex.h"
#include <vector>
usingnamespacellvm;
usingnamespacellvm::sys;
class DynamicLibrary::HandleSet { … };
namespace {
struct Globals { … };
Globals &getGlobals() { … }
}
#ifdef _WIN32
#include "Windows/DynamicLibrary.inc"
#else
#include "Unix/DynamicLibrary.inc"
#endif
char DynamicLibrary::Invalid;
DynamicLibrary::SearchOrdering DynamicLibrary::SearchOrder = …;
namespace llvm {
void *SearchForAddressOfSpecialSymbol(const char *SymbolName) { … }
}
void DynamicLibrary::AddSymbol(StringRef SymbolName, void *SymbolValue) { … }
DynamicLibrary DynamicLibrary::getPermanentLibrary(const char *FileName,
std::string *Err) { … }
DynamicLibrary DynamicLibrary::addPermanentLibrary(void *Handle,
std::string *Err) { … }
DynamicLibrary DynamicLibrary::getLibrary(const char *FileName,
std::string *Err) { … }
void DynamicLibrary::closeLibrary(DynamicLibrary &Lib) { … }
void *DynamicLibrary::getAddressOfSymbol(const char *SymbolName) { … }
void *DynamicLibrary::SearchForAddressOfSymbol(const char *SymbolName) { … }
LLVMBool LLVMLoadLibraryPermanently(const char *Filename) { … }
void *LLVMSearchForAddressOfSymbol(const char *symbolName) { … }
void LLVMAddSymbol(const char *symbolName, void *symbolValue) { … }