]> granicus.if.org Git - clang/commitdiff
Fix build failure on android due to missing std::to_string()
authorYaxun Liu <Yaxun.Liu@amd.com>
Sat, 14 Oct 2017 12:51:52 +0000 (12:51 +0000)
committerYaxun Liu <Yaxun.Liu@amd.com>
Sat, 14 Oct 2017 12:51:52 +0000 (12:51 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@315805 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/TargetInfo.cpp

index bca278019e1e7fe1afed0a5b0d1d299112754147..340fd55cc7bb26991d7d65670a6b0d80527874b4 100644 (file)
@@ -25,6 +25,7 @@
 #include "llvm/ADT/StringExtras.h"
 #include "llvm/ADT/StringSwitch.h"
 #include "llvm/ADT/Triple.h"
+#include "llvm/ADT/Twine.h"
 #include "llvm/IR/DataLayout.h"
 #include "llvm/IR/Type.h"
 #include "llvm/Support/raw_ostream.h"
@@ -8994,7 +8995,7 @@ llvm::Function *AMDGPUTargetCodeGenInfo::createEnqueuedBlockKernel(
     ArgBaseTypeNames.push_back(llvm::MDString::get(C, "void*"));
     ArgTypeQuals.push_back(llvm::MDString::get(C, ""));
     ArgNames.push_back(
-        llvm::MDString::get(C, std::string("local_arg") + std::to_string(I)));
+        llvm::MDString::get(C, (Twine("local_arg") + Twine(I)).str()));
   }
   std::string Name = Invoke->getName().str() + "_kernel";
   auto *FT = llvm::FunctionType::get(llvm::Type::getVoidTy(C), ArgTys, false);