OSDN Git Service

MC: Remove dead code. NFCI.
authorPeter Collingbourne <peter@pcc.me.uk>
Tue, 22 May 2018 01:20:46 +0000 (01:20 +0000)
committerPeter Collingbourne <peter@pcc.me.uk>
Tue, 22 May 2018 01:20:46 +0000 (01:20 +0000)
This code appears to have been copied from the mach-o streamer. It has
no effect in ELF because indirect symbols are specific to mach-o.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@332926 91177308-0d34-0410-b5e6-96231b3b80d8

lib/MC/MCELFStreamer.cpp

index 31c4135..3a008f9 100644 (file)
@@ -188,17 +188,6 @@ static unsigned CombineSymbolTypes(unsigned T1, unsigned T2) {
 
 bool MCELFStreamer::EmitSymbolAttribute(MCSymbol *S, MCSymbolAttr Attribute) {
   auto *Symbol = cast<MCSymbolELF>(S);
-  // Indirect symbols are handled differently, to match how 'as' handles
-  // them. This makes writing matching .o files easier.
-  if (Attribute == MCSA_IndirectSymbol) {
-    // Note that we intentionally cannot use the symbol data here; this is
-    // important for matching the string table that 'as' generates.
-    IndirectSymbolData ISD;
-    ISD.Symbol = Symbol;
-    ISD.Section = getCurrentSectionOnly();
-    getAssembler().getIndirectSymbols().push_back(ISD);
-    return true;
-  }
 
   // Adding a symbol attribute always introduces the symbol, note that an
   // important side effect of calling registerSymbol here is to register