[llvm] r251942 - [Kaleidoscope][Orc] Fix the fully_lazy Orc Kaleidoscope example.
Lang Hames via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 3 08:35:10 PST 2015
Author: lhames
Date: Tue Nov 3 10:35:10 2015
New Revision: 251942
URL: http://llvm.org/viewvc/llvm-project?rev=251942&view=rev
Log:
[Kaleidoscope][Orc] Fix the fully_lazy Orc Kaleidoscope example.
r251933 changed the Orc compile callbacks API, which broke this.
Modified:
llvm/trunk/examples/Kaleidoscope/Orc/fully_lazy/toy.cpp
Modified: llvm/trunk/examples/Kaleidoscope/Orc/fully_lazy/toy.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/examples/Kaleidoscope/Orc/fully_lazy/toy.cpp?rev=251942&r1=251941&r2=251942&view=diff
==============================================================================
--- llvm/trunk/examples/Kaleidoscope/Orc/fully_lazy/toy.cpp (original)
+++ llvm/trunk/examples/Kaleidoscope/Orc/fully_lazy/toy.cpp Tue Nov 3 10:35:10 2015
@@ -1168,9 +1168,7 @@ public:
: Session(Session),
CompileLayer(ObjectLayer, SimpleCompiler(Session.getTarget())),
LazyEmitLayer(CompileLayer),
- CompileCallbacks(LazyEmitLayer, CCMgrMemMgr, Session.getLLVMContext(),
- reinterpret_cast<uintptr_t>(EarthShatteringKaboom),
- 64) {}
+ CompileCallbacks(reinterpret_cast<uintptr_t>(EarthShatteringKaboom)) {}
std::string mangle(const std::string &Name) {
std::string MangledName;
@@ -1260,8 +1258,7 @@ private:
// the function. The resulting CallbackInfo type will let us set the
// compile and update actions for the callback, and get a pointer to
// the jit trampoline that we need to call to trigger those actions.
- auto CallbackInfo =
- CompileCallbacks.getCompileCallback(F->getContext());
+ auto CallbackInfo = CompileCallbacks.getCompileCallback();
// Step 3) Create a stub that will indirectly call the body of this
// function once it is compiled. Initially, set the function
@@ -1311,7 +1308,7 @@ private:
std::map<std::string, std::unique_ptr<FunctionAST>> FunctionDefs;
- JITCompileCallbackManager<LazyEmitLayerT, OrcX86_64> CompileCallbacks;
+ JITCompileCallbackManager<OrcX86_64> CompileCallbacks;
};
static void HandleDefinition(SessionContext &S, KaleidoscopeJIT &J) {
More information about the llvm-commits
mailing list