[Orc] New JIT APIs.
authorLang Hames <lhames@gmail.com>
Fri, 23 Jan 2015 21:25:00 +0000 (21:25 +0000)
committerLang Hames <lhames@gmail.com>
Fri, 23 Jan 2015 21:25:00 +0000 (21:25 +0000)
commit63cc4f56a92d80148009381616897c7a1836c296
tree2916fdf896e9e2942b2976d84d0db538179b07df
parentd5dc4cff6ab98daeaee1dbb340ebe9df47385dc6
[Orc] New JIT APIs.

This patch adds a new set of JIT APIs to LLVM. The aim of these new APIs is to
cleanly support a wider range of JIT use cases in LLVM, and encourage the
development and contribution of re-usable infrastructure for LLVM JIT use-cases.

These APIs are intended to live alongside the MCJIT APIs, and should not affect
existing clients.

Included in this patch:

1) New headers in include/llvm/ExecutionEngine/Orc that provide a set of
   components for building JIT infrastructure.
   Implementation code for these headers lives in lib/ExecutionEngine/Orc.

2) A prototype re-implementation of MCJIT (OrcMCJITReplacement) built out of the
   new components.

3) Minor changes to RTDyldMemoryManager needed to support the new components.
   These changes should not impact existing clients.

4) A new flag for lli, -use-orcmcjit, which will cause lli to use the
   OrcMCJITReplacement class as its underlying execution engine, rather than
   MCJIT itself.

Tests to follow shortly.

Special thanks to Michael Ilseman, Pete Cooper, David Blaikie, Eric Christopher,
Justin Bogner, and Jim Grosbach for extensive feedback and discussion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@226940 91177308-0d34-0410-b5e6-96231b3b80d8
29 files changed:
include/llvm/ExecutionEngine/ExecutionEngine.h
include/llvm/ExecutionEngine/ObjectMemoryBuffer.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/CloneSubModule.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/CompileOnDemandLayer.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/CompileUtils.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/IRCompileLayer.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/IndirectionUtils.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/LazyEmittingLayer.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/LookasideRTDyldMM.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/ObjectLinkingLayer.h [new file with mode: 0644]
include/llvm/ExecutionEngine/Orc/OrcTargetSupport.h [new file with mode: 0644]
include/llvm/ExecutionEngine/OrcMCJITReplacement.h [new file with mode: 0644]
include/llvm/ExecutionEngine/RTDyldMemoryManager.h
lib/ExecutionEngine/CMakeLists.txt
lib/ExecutionEngine/ExecutionEngine.cpp
lib/ExecutionEngine/LLVMBuild.txt
lib/ExecutionEngine/MCJIT/MCJIT.h
lib/ExecutionEngine/Makefile
lib/ExecutionEngine/Orc/CMakeLists.txt [new file with mode: 0644]
lib/ExecutionEngine/Orc/CloneSubModule.cpp [new file with mode: 0644]
lib/ExecutionEngine/Orc/IndirectionUtils.cpp [new file with mode: 0644]
lib/ExecutionEngine/Orc/LLVMBuild.txt [new file with mode: 0644]
lib/ExecutionEngine/Orc/Makefile [new file with mode: 0644]
lib/ExecutionEngine/Orc/OrcMCJITReplacement.cpp [new file with mode: 0644]
lib/ExecutionEngine/Orc/OrcMCJITReplacement.h [new file with mode: 0644]
lib/ExecutionEngine/Orc/OrcTargetSupport.cpp [new file with mode: 0644]
lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
tools/lli/CMakeLists.txt
tools/lli/lli.cpp