1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 02:52:53 +02:00
llvm-mirror/tools/lli
Lang Hames 6784638299 [ORC] Redesign the JITSymbolResolver interface to support bulk queries.
Bulk queries reduce IPC/RPC overhead for cross-process JITing and expose
opportunities for parallel compilation.

The two new query methods are lookupFlags, which finds the flags for each of a
set of symbols; and lookup, which finds the address and flags for each of a
set of symbols. (See doxygen comments for more details.)

The existing JITSymbolResolver class is renamed LegacyJITSymbolResolver, and
modified to extend the new JITSymbolResolver class using the following scheme:

- lookupFlags is implemented by calling findSymbolInLogicalDylib for each of the
symbols, then returning the result of calling getFlags() on each of these
symbols. (Importantly: lookupFlags does NOT call getAddress on the returned
symbols, so lookupFlags will never trigger materialization, and lookupFlags will
never call findSymbol, so only symbols that are part of the logical dylib will
return results.)

- lookup is implemented by calling findSymbolInLogicalDylib for each symbol and
falling back to findSymbol if findSymbolInLogicalDylib returns a null result.
Assuming a symbol is found its getAddress method is called to materialize it and
the result (if getAddress succeeds) is stored in the result map, or the error
(if getAddress fails) is returned immediately from lookup. If any symbol is not
found then lookup returns immediately with an error.

This change will break any out-of-tree derivatives of JITSymbolResolver. This
can be fixed by updating those classes to derive from LegacyJITSymbolResolver
instead.

llvm-svn: 322913
2018-01-19 01:12:40 +00:00
..
ChildTarget [CMake] lli-child-target depends on intrinsics gen 2016-11-19 02:09:51 +00:00
CMakeLists.txt Prune unused libdeps. 2016-12-08 15:28:02 +00:00
lli.cpp [lli] Make lli support -mcpu=native for CPU autodetection 2018-01-09 18:14:18 +00:00
LLVMBuild.txt
OrcLazyJIT.cpp [ORC] Errorize the ORC APIs. 2017-07-07 02:59:13 +00:00
OrcLazyJIT.h Untabify. 2017-08-28 06:47:47 +00:00
RemoteJITUtils.h [ORC] Redesign the JITSymbolResolver interface to support bulk queries. 2018-01-19 01:12:40 +00:00