Move stack protector names to the same place.
authorBill Wendling <isanbard@gmail.com>
Mon, 12 Aug 2013 20:09:37 +0000 (20:09 +0000)
committerBill Wendling <isanbard@gmail.com>
Mon, 12 Aug 2013 20:09:37 +0000 (20:09 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188198 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/IPO/Internalize.cpp

index d56a06f8d6fa4eedfbfcf78f33fb183afedb03ff..26743dc3f0f9c48fffec208845d618851696d6cd 100644 (file)
@@ -114,11 +114,6 @@ bool InternalizePass::runOnModule(Module &M) {
   CallGraphNode *ExternalNode = CG ? CG->getExternalCallingNode() : 0;
   bool Changed = false;
 
-  // Never internalize functions which code-gen might insert.
-  // FIXME: We should probably add this (and the __stack_chk_guard) via some
-  // type of call-back in CodeGen.
-  ExternalNames.insert("__stack_chk_fail");
-
   SmallPtrSet<GlobalValue *, 8> Used;
   collectUsedGlobalVariables(M, Used, false);
 
@@ -166,6 +161,9 @@ bool InternalizePass::runOnModule(Module &M) {
   ExternalNames.insert("llvm.global.annotations");
 
   // Never internalize symbols code-gen inserts.
+  // FIXME: We should probably add this (and the __stack_chk_guard) via some
+  // type of call-back in CodeGen.
+  ExternalNames.insert("__stack_chk_fail");
   ExternalNames.insert("__stack_chk_guard");
 
   // Mark all global variables with initializers that are not in the api as