lto: Fix an inverted conditional which prevented the addition of symbols scraped
authorDaniel Dunbar <daniel@zuster.org>
Wed, 11 Aug 2010 00:11:19 +0000 (00:11 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Wed, 11 Aug 2010 00:11:19 +0000 (00:11 +0000)
from inline assembly, except in cases where they had already been seen (in which
case they would get added twice).
 - I can't see how this ever worked...

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

tools/lto/LTOModule.cpp

index e329d508c88b41b54174e4294d561a4128b8f6a2..c7cd585d03ddf1b1affd989c8f2b787e88b7dbac 100644 (file)
@@ -356,7 +356,7 @@ void LTOModule::addDefinedSymbol(GlobalValue *def, Mangler &mangler,
 
 void LTOModule::addAsmGlobalSymbol(const char *name) {
   // only add new define if not already defined
-  if (_defines.count(name) == 0)
+  if (_defines.count(name))
     return;
 
   // string is owned by _defines