summaryrefslogtreecommitdiffstats
path: root/llvm/tools/lli/OrcLazyJIT.h
diff options
context:
space:
mode:
authorEugene Zelenko <eugene.zelenko@gmail.com>2017-06-19 23:37:52 +0000
committerEugene Zelenko <eugene.zelenko@gmail.com>2017-06-19 23:37:52 +0000
commitf292a2feca7165eb94cc6b6775a87e3c2c32422e (patch)
treea3de007469686421d88bbce46d1140ce1443cf0f /llvm/tools/lli/OrcLazyJIT.h
parent50c2f251f54935471464e2d1850858b633f46c38 (diff)
downloadbcm5719-llvm-f292a2feca7165eb94cc6b6775a87e3c2c32422e.tar.gz
bcm5719-llvm-f292a2feca7165eb94cc6b6775a87e3c2c32422e.zip
[ExecutionEngine] Fix some Clang-tidy modernize-use-using and Include What You Use warnings; other minor fixes (NFC).
llvm-svn: 305760
Diffstat (limited to 'llvm/tools/lli/OrcLazyJIT.h')
-rw-r--r--llvm/tools/lli/OrcLazyJIT.h47
1 files changed, 30 insertions, 17 deletions
diff --git a/llvm/tools/lli/OrcLazyJIT.h b/llvm/tools/lli/OrcLazyJIT.h
index 56e7d36d05f..9a137a5abe8 100644
--- a/llvm/tools/lli/OrcLazyJIT.h
+++ b/llvm/tools/lli/OrcLazyJIT.h
@@ -1,4 +1,4 @@
-//===--- OrcLazyJIT.h - Basic Orc-based JIT for lazy execution --*- C++ -*-===//
+//===- OrcLazyJIT.h - Basic Orc-based JIT for lazy execution ----*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
@@ -15,38 +15,52 @@
#ifndef LLVM_TOOLS_LLI_ORCLAZYJIT_H
#define LLVM_TOOLS_LLI_ORCLAZYJIT_H
-#include "llvm/ADT/Triple.h"
+#include "llvm/ADT/STLExtras.h"
+#include "llvm/ADT/Twine.h"
+#include "llvm/ExecutionEngine/JITSymbol.h"
#include "llvm/ExecutionEngine/Orc/CompileOnDemandLayer.h"
#include "llvm/ExecutionEngine/Orc/CompileUtils.h"
#include "llvm/ExecutionEngine/Orc/ExecutionUtils.h"
+#include "llvm/ExecutionEngine/Orc/IndirectionUtils.h"
#include "llvm/ExecutionEngine/Orc/IRCompileLayer.h"
#include "llvm/ExecutionEngine/Orc/IRTransformLayer.h"
+#include "llvm/ExecutionEngine/Orc/LambdaResolver.h"
#include "llvm/ExecutionEngine/Orc/RTDyldObjectLinkingLayer.h"
#include "llvm/ExecutionEngine/RTDyldMemoryManager.h"
+#include "llvm/ExecutionEngine/SectionMemoryManager.h"
+#include "llvm/IR/DataLayout.h"
+#include "llvm/IR/GlobalValue.h"
+#include "llvm/IR/Mangler.h"
+#include "llvm/IR/Module.h"
+#include "llvm/Support/raw_ostream.h"
+#include "llvm/Target/TargetMachine.h"
+#include <algorithm>
+#include <functional>
+#include <memory>
+#include <set>
+#include <string>
+#include <vector>
namespace llvm {
class OrcLazyJIT {
public:
-
- typedef orc::JITCompileCallbackManager CompileCallbackMgr;
- typedef orc::RTDyldObjectLinkingLayer<> ObjLayerT;
- typedef orc::IRCompileLayer<ObjLayerT> CompileLayerT;
- typedef std::function<std::unique_ptr<Module>(std::unique_ptr<Module>)>
- TransformFtor;
- typedef orc::IRTransformLayer<CompileLayerT, TransformFtor> IRDumpLayerT;
- typedef orc::CompileOnDemandLayer<IRDumpLayerT, CompileCallbackMgr> CODLayerT;
- typedef CODLayerT::IndirectStubsManagerBuilderT
- IndirectStubsManagerBuilder;
- typedef CODLayerT::ModuleSetHandleT ModuleSetHandleT;
+ using CompileCallbackMgr = orc::JITCompileCallbackManager;
+ using ObjLayerT = orc::RTDyldObjectLinkingLayer<>;
+ using CompileLayerT = orc::IRCompileLayer<ObjLayerT>;
+ using TransformFtor =
+ std::function<std::unique_ptr<Module>(std::unique_ptr<Module>)>;
+ using IRDumpLayerT = orc::IRTransformLayer<CompileLayerT, TransformFtor>;
+ using CODLayerT = orc::CompileOnDemandLayer<IRDumpLayerT, CompileCallbackMgr>;
+ using IndirectStubsManagerBuilder = CODLayerT::IndirectStubsManagerBuilderT;
+ using ModuleSetHandleT = CODLayerT::ModuleSetHandleT;
OrcLazyJIT(std::unique_ptr<TargetMachine> TM,
std::unique_ptr<CompileCallbackMgr> CCMgr,
IndirectStubsManagerBuilder IndirectStubsMgrBuilder,
bool InlineStubs)
: TM(std::move(TM)), DL(this->TM->createDataLayout()),
- CCMgr(std::move(CCMgr)),
- ObjectLayer(),
+ CCMgr(std::move(CCMgr)),
CompileLayer(ObjectLayer, orc::SimpleCompiler(*this->TM)),
IRDumpLayer(CompileLayer, createDebugDumper()),
CODLayer(IRDumpLayer, extractSingleFunction, *this->CCMgr,
@@ -135,7 +149,6 @@ public:
}
private:
-
std::string mangle(const std::string &Name) {
std::string MangledName;
{
@@ -172,4 +185,4 @@ int runOrcLazyJIT(std::vector<std::unique_ptr<Module>> Ms,
} // end namespace llvm
-#endif
+#endif // LLVM_TOOLS_LLI_ORCLAZYJIT_H
OpenPOWER on IntegriCloud