]> granicus.if.org Git - clang/commitdiff
PGO: Switch to isOSBinFormatMachO()
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Tue, 18 Mar 2014 00:39:26 +0000 (00:39 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Tue, 18 Mar 2014 00:39:26 +0000 (00:39 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204098 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CodeGenPGO.cpp

index 1d3ee4f8a6c8214f9049b06f1f8b2907aa9341b9..207cb665b0fc53f7d58ce127c6f650ba38c7e379 100644 (file)
@@ -213,21 +213,21 @@ static llvm::Constant *getOrInsertRuntimeWriteAtExit(CodeGenModule &CGM) {
 }
 
 static StringRef getCountersSection(const CodeGenModule &CGM) {
-  if (CGM.getTarget().getTriple().getObjectFormat() == llvm::Triple::MachO)
+  if (CGM.getTarget().getTriple().isOSBinFormatMachO())
     return "__DATA,__llvm_pgo_cnts";
   else
     return "__llvm_pgo_cnts";
 }
 
 static StringRef getNameSection(const CodeGenModule &CGM) {
-  if (CGM.getTarget().getTriple().getObjectFormat() == llvm::Triple::MachO)
+  if (CGM.getTarget().getTriple().isOSBinFormatMachO())
     return "__DATA,__llvm_pgo_names";
   else
     return "__llvm_pgo_names";
 }
 
 static StringRef getDataSection(const CodeGenModule &CGM) {
-  if (CGM.getTarget().getTriple().getObjectFormat() == llvm::Triple::MachO)
+  if (CGM.getTarget().getTriple().isOSBinFormatMachO())
     return "__DATA,__llvm_pgo_data";
   else
     return "__llvm_pgo_data";