LLVM API Documentation
#include "llvm/Linker.h"
#include "llvm-c/Linker.h"
#include "llvm/ADT/Optional.h"
#include "llvm/ADT/SetVector.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Module.h"
#include "llvm/IR/TypeFinder.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/Transforms/Utils/Cloning.h"
#include <cctype>
Go to the source code of this file.
Functions | |
static void | forceRenaming (GlobalValue *GV, StringRef Name) |
static void | copyGVAttributes (GlobalValue *DestGV, const GlobalValue *SrcGV) |
static bool | isLessConstraining (GlobalValue::VisibilityTypes a, GlobalValue::VisibilityTypes b) |
static void | getArrayElements (Constant *C, SmallVectorImpl< Constant * > &Dest) |
LLVMBool | LLVMLinkModules (LLVMModuleRef Dest, LLVMModuleRef Src, LLVMLinkerMode Mode, char **OutMessages) |
|
static |
copyGVAttributes - copy additional attributes (those not needed to construct a GlobalValue) from the SrcGV to the DestGV.
Definition at line 491 of file LinkModules.cpp.
References llvm::GlobalValue::copyAttributesFrom(), forceRenaming(), llvm::GlobalValue::getAlignment(), llvm::Value::getName(), and llvm::GlobalValue::setAlignment().
|
static |
forceRenaming - The LLVM SymbolTable class autorenames globals that conflict in the symbol table. This is good for all clients except for us. Go through the trouble to force this back.
Definition at line 471 of file LinkModules.cpp.
References llvm::Value::getName(), llvm::Module::getNamedValue(), llvm::GlobalValue::getParent(), llvm::GlobalValue::hasLocalLinkage(), llvm::Value::setName(), and llvm::Value::takeName().
Referenced by copyGVAttributes().
|
static |
Definition at line 928 of file LinkModules.cpp.
References llvm::Constant::getAggregateElement(), llvm::Value::getType(), and llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back().
|
static |
Definition at line 500 of file LinkModules.cpp.
References llvm::GlobalValue::HiddenVisibility, and llvm::GlobalValue::ProtectedVisibility.
LLVMBool LLVMLinkModules | ( | LLVMModuleRef | Dest, |
LLVMModuleRef | Src, | ||
LLVMLinkerMode | Mode, | ||
char ** | OutMessages | ||
) |
Definition at line 1389 of file LinkModules.cpp.
References llvm::Linker::LinkModules(), llvm::LibFunc::strdup, and llvm::unwrap().