LLVM API Documentation
#include <Mangler.h>
Public Types | |
enum | ManglerPrefixTy { Default, Private, LinkerPrivate } |
Public Member Functions | |
Mangler (const TargetMachine *TM) | |
void | getNameWithPrefix (SmallVectorImpl< char > &OutName, const GlobalValue *GV, bool isImplicitlyPrivate, bool UseGlobalPrefix=true) |
void | getNameWithPrefix (SmallVectorImpl< char > &OutName, const Twine &GVName, ManglerPrefixTy PrefixTy=Mangler::Default, bool UseGlobalPrefix=true) |
|
inline |
void Mangler::getNameWithPrefix | ( | SmallVectorImpl< char > & | OutName, |
const GlobalValue * | GV, | ||
bool | isImplicitlyPrivate, | ||
bool | UseGlobalPrefix = true |
||
) |
getNameWithPrefix - Fill OutName with the name of the appropriate prefix and the specified global variable's name. If the global variable doesn't have a name, this fills in a unique name for the global.
Definition at line 90 of file Mangler.cpp.
References AddFastCallStdCallSuffix(), llvm::SmallVectorTemplateCommon< T, typename >::begin(), Default, F(), llvm::TargetMachine::getDataLayout(), llvm::TargetMachine::getMCAsmInfo(), llvm::Value::getName(), llvm::FunctionType::getNumParams(), llvm::GlobalValue::hasLinkerPrivateLinkage(), llvm::GlobalValue::hasLinkerPrivateWeakLinkage(), llvm::MCAsmInfo::hasMicrosoftFastStdCallMangling(), llvm::Value::hasName(), llvm::GlobalValue::hasPrivateLinkage(), llvm::SmallVectorImpl< T >::insert(), llvm::FunctionType::isVarArg(), LinkerPrivate, Private, llvm::CallingConv::X86_FastCall, and llvm::CallingConv::X86_StdCall.
Referenced by EmitCamlGlobal(), llvm::TargetLoweringObjectFileMachO::getCFIPersonalitySymbol(), llvm::TargetLoweringObjectFileCOFF::getExplicitSectionGlobal(), llvm::AsmPrinter::GetExternalSymbolSymbol(), llvm::TargetLoweringObjectFile::getSymbol(), GetSymbolFromOperand(), llvm::AsmPrinter::GetSymbolWithGlobalValueBase(), llvm::TargetLoweringObjectFileELF::getTTypeGlobalReference(), llvm::TargetLoweringObjectFileMachO::getTTypeGlobalReference(), and llvm::TargetLoweringObjectFileCOFF::SelectSectionForGlobal().
void Mangler::getNameWithPrefix | ( | SmallVectorImpl< char > & | OutName, |
const Twine & | GVName, | ||
ManglerPrefixTy | PrefixTy = Mangler::Default , |
||
bool | UseGlobalPrefix = true |
||
) |
getNameWithPrefix - Fill OutName with the name of the appropriate prefix and the specified name as the global variable name. GVName must not be empty.
Definition at line 29 of file Mangler.cpp.
References llvm::SmallVectorImpl< T >::append(), llvm::StringRef::begin(), llvm::StringRef::empty(), llvm::StringRef::end(), llvm::TargetMachine::getMCAsmInfo(), LinkerPrivate, llvm::cl::Prefix, Private, llvm::SmallVectorTemplateBase< T, isPodLike >::push_back(), llvm::LibFunc::strlen, llvm::StringRef::substr(), and llvm::Twine::toStringRef().