diff options
author | Chris Lattner <sabre@nondot.org> | 2009-07-31 20:52:39 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-07-31 20:52:39 +0000 |
commit | d25701c114e108af5e2f9f40a05c6ad0276ecb40 (patch) | |
tree | c8e4cad3867b1623a78a35a34f5ae6f9a5a62eca /llvm/lib/Target/DarwinTargetAsmInfo.cpp | |
parent | f3ee7eaac3a75c91703f04bab1040792a414e5a9 (diff) | |
download | bcm5719-llvm-d25701c114e108af5e2f9f40a05c6ad0276ecb40.tar.gz bcm5719-llvm-d25701c114e108af5e2f9f40a05c6ad0276ecb40.zip |
move emitUsedDirectiveFor to TargetLoweringObjectFile and rename it to
indicate that it is a predicate, not an emitter. This eliminates TAI
dependencies on Mangler and GlobalValue.
llvm-svn: 77726
Diffstat (limited to 'llvm/lib/Target/DarwinTargetAsmInfo.cpp')
-rw-r--r-- | llvm/lib/Target/DarwinTargetAsmInfo.cpp | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/llvm/lib/Target/DarwinTargetAsmInfo.cpp b/llvm/lib/Target/DarwinTargetAsmInfo.cpp index aa93c0d1196..306300ec889 100644 --- a/llvm/lib/Target/DarwinTargetAsmInfo.cpp +++ b/llvm/lib/Target/DarwinTargetAsmInfo.cpp @@ -79,23 +79,3 @@ DarwinTargetAsmInfo::DarwinTargetAsmInfo(const TargetMachine &TM) DwarfMacroInfoSection = ".section __DWARF,__debug_macinfo,regular,debug"; } -/// emitUsedDirectiveFor - On Darwin, internally linked data beginning with -/// the PrivateGlobalPrefix or the LinkerPrivateGlobalPrefix does not have the -/// directive emitted (this occurs in ObjC metadata). -bool DarwinTargetAsmInfo::emitUsedDirectiveFor(const GlobalValue* GV, - Mangler *Mang) const { - if (!GV) return false; - - // Check whether the mangled name has the "Private" or "LinkerPrivate" prefix. - if (GV->hasLocalLinkage() && !isa<Function>(GV)) { - // FIXME: ObjC metadata is currently emitted as internal symbols that have - // \1L and \0l prefixes on them. Fix them to be Private/LinkerPrivate and - // this horrible hack can go away. - const std::string &Name = Mang->getMangledName(GV); - if (Name[0] == 'L' || Name[0] == 'l') - return false; - } - - return true; -} - |