diff options
author | Jonas Devlieghere <jonas@devlieghere.com> | 2019-08-15 15:54:37 +0000 |
---|---|---|
committer | Jonas Devlieghere <jonas@devlieghere.com> | 2019-08-15 15:54:37 +0000 |
commit | 0eaee545eef49ff9498234d3a51a5cbde59bf976 (patch) | |
tree | fd7691e102022fb97622c5485fa8c4f506fc124e /llvm/lib/ExecutionEngine/Orc/LLJIT.cpp | |
parent | 1c34d10776828c0756ff4f0b2b9aa8bda2be348a (diff) | |
download | bcm5719-llvm-0eaee545eef49ff9498234d3a51a5cbde59bf976.tar.gz bcm5719-llvm-0eaee545eef49ff9498234d3a51a5cbde59bf976.zip |
[llvm] Migrate llvm::make_unique to std::make_unique
Now that we've moved to C++14, we no longer need the llvm::make_unique
implementation from STLExtras.h. This patch is a mechanical replacement
of (hopefully) all the llvm::make_unique instances across the monorepo.
llvm-svn: 369013
Diffstat (limited to 'llvm/lib/ExecutionEngine/Orc/LLJIT.cpp')
-rw-r--r-- | llvm/lib/ExecutionEngine/Orc/LLJIT.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/llvm/lib/ExecutionEngine/Orc/LLJIT.cpp b/llvm/lib/ExecutionEngine/Orc/LLJIT.cpp index 05ebb746985..a80f78afe80 100644 --- a/llvm/lib/ExecutionEngine/Orc/LLJIT.cpp +++ b/llvm/lib/ExecutionEngine/Orc/LLJIT.cpp @@ -68,9 +68,9 @@ LLJIT::createObjectLinkingLayer(LLJITBuilderState &S, ExecutionSession &ES) { // Otherwise default to creating an RTDyldObjectLinkingLayer that constructs // a new SectionMemoryManager for each object. - auto GetMemMgr = []() { return llvm::make_unique<SectionMemoryManager>(); }; + auto GetMemMgr = []() { return std::make_unique<SectionMemoryManager>(); }; auto ObjLinkingLayer = - llvm::make_unique<RTDyldObjectLinkingLayer>(ES, std::move(GetMemMgr)); + std::make_unique<RTDyldObjectLinkingLayer>(ES, std::move(GetMemMgr)); if (S.JTMB->getTargetTriple().isOSBinFormatCOFF()) ObjLinkingLayer->setOverrideObjectFlagsWithResponsibilityFlags(true); @@ -102,7 +102,7 @@ LLJIT::createCompileFunction(LLJITBuilderState &S, } LLJIT::LLJIT(LLJITBuilderState &S, Error &Err) - : ES(S.ES ? std::move(S.ES) : llvm::make_unique<ExecutionSession>()), + : ES(S.ES ? std::move(S.ES) : std::make_unique<ExecutionSession>()), Main(this->ES->getMainJITDylib()), DL(""), CtorRunner(Main), DtorRunner(Main) { @@ -123,13 +123,13 @@ LLJIT::LLJIT(LLJITBuilderState &S, Error &Err) Err = CompileFunction.takeError(); return; } - CompileLayer = llvm::make_unique<IRCompileLayer>( + CompileLayer = std::make_unique<IRCompileLayer>( *ES, *ObjLinkingLayer, std::move(*CompileFunction)); } if (S.NumCompileThreads > 0) { CompileLayer->setCloneToNewContextOnEmit(true); - CompileThreads = llvm::make_unique<ThreadPool>(S.NumCompileThreads); + CompileThreads = std::make_unique<ThreadPool>(S.NumCompileThreads); ES->setDispatchMaterialization( [this](JITDylib &JD, std::unique_ptr<MaterializationUnit> MU) { // FIXME: Switch to move capture once we have c++14. @@ -226,10 +226,10 @@ LLLazyJIT::LLLazyJIT(LLLazyJITBuilderState &S, Error &Err) : LLJIT(S, Err) { } // Create the transform layer. - TransformLayer = llvm::make_unique<IRTransformLayer>(*ES, *CompileLayer); + TransformLayer = std::make_unique<IRTransformLayer>(*ES, *CompileLayer); // Create the COD layer. - CODLayer = llvm::make_unique<CompileOnDemandLayer>( + CODLayer = std::make_unique<CompileOnDemandLayer>( *ES, *TransformLayer, *LCTMgr, std::move(ISMBuilder)); if (S.NumCompileThreads > 0) |