OSDN Git Service

Use new interface in Triple /NFC
authorXinliang David Li <davidxl@google.com>
Thu, 26 May 2016 16:28:01 +0000 (16:28 +0000)
committerXinliang David Li <davidxl@google.com>
Thu, 26 May 2016 16:28:01 +0000 (16:28 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@270865 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Instrumentation/PGOInstrumentation.cpp

index 835f75e..9f980da 100644 (file)
@@ -790,7 +790,7 @@ static void createIRLevelProfileFlagVariable(Module &M) {
       INSTR_PROF_QUOTE(IR_LEVEL_PROF_VERSION_VAR));
   IRLevelVersionVariable->setVisibility(GlobalValue::DefaultVisibility);
   Triple TT(M.getTargetTriple());
-  if (TT.isOSBinFormatMachO())
+  if (!TT.supportsCOMDAT())
     IRLevelVersionVariable->setLinkage(GlobalValue::WeakAnyLinkage);
   else
     IRLevelVersionVariable->setComdat(M.getOrInsertComdat(