mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-18 13:34:04 +00:00
[orcjit] Include CMake support for the fully_lazy example and fix the build
Not sure if/how to make the CMake build use C++14 for the examples, so let's stick to C++11 for now. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229888 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
27eb697fea
commit
9be681366a
@ -1,3 +1,4 @@
|
||||
add_subdirectory(initial)
|
||||
add_subdirectory(lazy_codegen)
|
||||
add_subdirectory(lazy_irgen)
|
||||
add_subdirectory(fully_lazy)
|
||||
|
@ -2,11 +2,12 @@ set(LLVM_LINK_COMPONENTS
|
||||
Core
|
||||
ExecutionEngine
|
||||
Object
|
||||
OrcJIT
|
||||
RuntimeDyld
|
||||
Support
|
||||
native
|
||||
)
|
||||
|
||||
add_kaleidoscope_chapter(Kaleidoscope-Orc-lazy_irgen
|
||||
add_kaleidoscope_chapter(Kaleidoscope-Orc-fully_lazy
|
||||
toy.cpp
|
||||
)
|
||||
|
@ -1280,11 +1280,11 @@ private:
|
||||
//
|
||||
// The update action will update FunctionBodyPointer to point at the newly
|
||||
// compiled function.
|
||||
CallbackInfo.setCompileAction(
|
||||
[this, Fn = std::shared_ptr<FunctionAST>(std::move(FnAST))](){
|
||||
auto H = addModule(IRGen(Session, *Fn));
|
||||
return findSymbolIn(H, Fn->Proto->Name).getAddress();
|
||||
});
|
||||
std::shared_ptr<FunctionAST> Fn = std::move(FnAST);
|
||||
CallbackInfo.setCompileAction([this, Fn]() {
|
||||
auto H = addModule(IRGen(Session, *Fn));
|
||||
return findSymbolIn(H, Fn->Proto->Name).getAddress();
|
||||
});
|
||||
CallbackInfo.setUpdateAction(
|
||||
CompileCallbacks.getLocalFPUpdater(H, Mangle(BodyPtrName)));
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user