<feed xmlns='http://www.w3.org/2005/Atom'>
<title>bcm5719-llvm/llvm/tools/lli, branch meklort-10.0.1</title>
<subtitle>Project Ortega BCM5719 LLVM</subtitle>
<id>https://git.raptorcs.com/git/bcm5719-llvm/atom?h=meklort-10.0.1</id>
<link rel='self' href='https://git.raptorcs.com/git/bcm5719-llvm/atom?h=meklort-10.0.1'/>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/'/>
<updated>2020-01-29T20:50:16+00:00</updated>
<entry>
<title>[ORC] Add support for emulated TLS to ORCv2.</title>
<updated>2020-01-29T20:50:16+00:00</updated>
<author>
<name>Lang Hames</name>
<email>lhames@gmail.com</email>
</author>
<published>2020-01-22T00:28:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=32723d572077e9a3776553a2067563974e85e7c8'/>
<id>urn:sha1:32723d572077e9a3776553a2067563974e85e7c8</id>
<content type='text'>
This commit adds a ManglingOptions struct to IRMaterializationUnit, and replaces
IRCompileLayer::CompileFunction with a new IRCompileLayer::IRCompiler class. The
ManglingOptions struct defines the emulated-TLS state (via a bool member,
EmulatedTLS, which is true if emulated-TLS is enabled and false otherwise). The
IRCompileLayer::IRCompiler class wraps an IRCompiler (the same way that the
CompileFunction typedef used to), but adds a method to return the
IRCompileLayer::ManglingOptions that the compiler will use.

These changes allow us to correctly determine the symbols that will be produced
when a thread local global variable defined at the IR level is compiled with or
without emulated TLS. This is required for ORCv2, where MaterializationUnits
must declare their interface up-front.

Most ORCv2 clients should not require any changes. Clients writing custom IR
compilers will need to wrap their compiler in an IRCompileLayer::IRCompiler,
rather than an IRCompileLayer::CompileFunction, however this should be a
straightforward change (see modifications to CompileUtils.* in this patch for an
example).

(cherry picked from commit ce2207abaf9a925b35f15ef92aaff6b301ba6d22)
</content>
</entry>
<entry>
<title>[ORC] Fix argv handling in runAsMain / lli.</title>
<updated>2020-01-11T21:03:38+00:00</updated>
<author>
<name>Lang Hames</name>
<email>lhames@gmail.com</email>
</author>
<published>2020-01-11T20:58:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=2cdb18afda841392002feafda21af31854c195b3'/>
<id>urn:sha1:2cdb18afda841392002feafda21af31854c195b3</id>
<content type='text'>
This fixes an off-by-one error in the argc value computed by runAsMain, and
switches lli back to using the input bitcode (rather than the string "lli") as
the effective program name.

Thanks to Stefan Graenitz for spotting the bug.
</content>
</entry>
<entry>
<title>[lli] Add a filter to avoid importing the process's main symbol.</title>
<updated>2020-01-03T00:05:23+00:00</updated>
<author>
<name>Lang Hames</name>
<email>lhames@gmail.com</email>
</author>
<published>2020-01-02T23:47:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=355983103f008b094b5cdd26233eb0ed7113e7ec'/>
<id>urn:sha1:355983103f008b094b5cdd26233eb0ed7113e7ec</id>
<content type='text'>
If JIT'd code fails to define a main function and we import the process's
definition then we will end up recursively calling lli's main until we overflow
the stack and crash. This filter fixes the issue by ensuring that the process's
main function is never imported. This results in lli producing a much friendlier
"symbol not found" error when JIT'd code fails to define main.
</content>
</entry>
<entry>
<title>[ORC] Add a runAsMain utility function to ExecutionUtils.</title>
<updated>2019-12-02T09:52:52+00:00</updated>
<author>
<name>Lang Hames</name>
<email>lhames@gmail.com</email>
</author>
<published>2019-12-02T09:45:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=ece8fed609061638bc867ecb74e179cb86426d60'/>
<id>urn:sha1:ece8fed609061638bc867ecb74e179cb86426d60</id>
<content type='text'>
The runAsMain function takes a pointer to a function with a standard C main
signature, int(*)(int, char*[]), and invokes it using the given arguments and
program name. The arguments are copied into writable temporary storage as
required by the C and C++ specifications, so runAsMain safe to use when calling
main functions that modify their arguments in-place.

This patch also uses the new runAsMain function to replace hand-rolled versions
in lli, llvm-jitlink, and the SpeculativeJIT example.
</content>
</entry>
<entry>
<title>[lli-child-target] Fix -DBUILD_SHARED_LIBS=on build</title>
<updated>2019-10-30T05:46:13+00:00</updated>
<author>
<name>Fangrui Song</name>
<email>maskray@google.com</email>
</author>
<published>2019-10-30T05:46:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=46ed00c383eacc3eb8c5d539c604f7175ba74526'/>
<id>urn:sha1:46ed00c383eacc3eb8c5d539c604f7175ba74526</id>
<content type='text'>
</content>
</entry>
<entry>
<title>[lli] Fix -DBUILD_SHARED_LIBS=on build</title>
<updated>2019-10-30T05:41:35+00:00</updated>
<author>
<name>Fangrui Song</name>
<email>maskray@google.com</email>
</author>
<published>2019-10-30T05:37:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=0c5bcd1b59828cd09c1a105e077bd6e8aff9ac51'/>
<id>urn:sha1:0c5bcd1b59828cd09c1a105e077bd6e8aff9ac51</id>
<content type='text'>
This fixes:

  ld.lld: error: undefined symbol: vtable for llvm::orc::rpc::ResponseAbandoned
  &gt;&gt;&gt; referenced by lli.cpp

In -DBUILD_SHARED_LIBS=on builds, all directly referenced references must
be linked to appease -Wl,-z,defs.
</content>
</entry>
<entry>
<title>Break out OrcError and RPC</title>
<updated>2019-10-30T00:31:28+00:00</updated>
<author>
<name>Chris Bieneman</name>
<email>chris.bieneman@me.com</email>
</author>
<published>2019-10-09T21:27:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=a34680a33eb1caa5e224a9432e9f3e643824dc2d'/>
<id>urn:sha1:a34680a33eb1caa5e224a9432e9f3e643824dc2d</id>
<content type='text'>
Summary:
When createing an ORC remote JIT target the current library split forces the target process to link large portions of LLVM (Core, Execution Engine, JITLink, Object, MC, Passes, RuntimeDyld, Support, Target, and TransformUtils). This occurs because the ORC RPC interfaces rely on the static globals the ORC Error types require, which starts a cycle of pulling in more and more.

This patch breaks the ORC RPC Error implementations out into an "OrcError" library which only depends on LLVM Support. It also pulls the ORC RPC headers into their own subdirectory.

With this patch code can include the Orc/RPC/*.h headers and will only incur link dependencies on LLVMOrcError and LLVMSupport.

Reviewers: lhames

Reviewed By: lhames

Subscribers: mgorny, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D68732
</content>
</entry>
<entry>
<title>[cmake] Link in LLVMPasses due to dependency by LLVMOrcJIT; NFC</title>
<updated>2019-08-19T23:12:48+00:00</updated>
<author>
<name>Hubert Tong</name>
<email>hubert.reinterpretcast@gmail.com</email>
</author>
<published>2019-08-19T23:12:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=71974b517550fbcf3b24dc1cf9f8de4a343c86de'/>
<id>urn:sha1:71974b517550fbcf3b24dc1cf9f8de4a343c86de</id>
<content type='text'>
Summary:
rL367756 (f5c40cb) increases the dependency of LLVMOrcJIT on LLVMPasses.
In particular, symbols defined in LLVMPasses that are referenced by the
destructor of `PassBuilder` are now referenced by LLVMOrcJIT through
`Speculation.cpp.o`.

We believe that referencing symbols defined in LLVMPasses in the
destructor of `PassBuilder` is valid, and that adding to the set of such
symbols is legitimate. To support such cases, this patch adds LLVMPasses
to the set of libraries being linked when linking in LLVMOrcJIT causes
such symbols from LLVMPasses to be referenced.

Reviewers: Whitney, anhtuyen, pree-jackie

Reviewed By: pree-jackie

Subscribers: mgorny, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D66441

llvm-svn: 369310
</content>
</entry>
<entry>
<title>[llvm] Migrate llvm::make_unique to std::make_unique</title>
<updated>2019-08-15T15:54:37+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2019-08-15T15:54:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=0eaee545eef49ff9498234d3a51a5cbde59bf976'/>
<id>urn:sha1:0eaee545eef49ff9498234d3a51a5cbde59bf976</id>
<content type='text'>
Now that we've moved to C++14, we no longer need the llvm::make_unique
implementation from STLExtras.h. This patch is a mechanical replacement
of (hopefully) all the llvm::make_unique instances across the monorepo.

llvm-svn: 369013
</content>
</entry>
<entry>
<title>[ORC] Refactor definition-generation, add a generator for static libraries.</title>
<updated>2019-08-13T16:05:18+00:00</updated>
<author>
<name>Lang Hames</name>
<email>lhames@gmail.com</email>
</author>
<published>2019-08-13T16:05:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/bcm5719-llvm/commit/?id=52a34a78d9aff1bb5e66e7c32490229ea177e075'/>
<id>urn:sha1:52a34a78d9aff1bb5e66e7c32490229ea177e075</id>
<content type='text'>
This patch replaces the JITDylib::DefinitionGenerator typedef with a class of
the same name, and adds support for attaching a sequence of DefinitionGeneration
objects to a JITDylib.

This patch also adds a new definition generator,
StaticLibraryDefinitionGenerator, that can be used to add symbols fom a static
library to a JITDylib. An object from the static library will be added (via
a supplied ObjectLayer reference) whenever a symbol from that object is
referenced.

To enable testing, lli is updated to add support for the --extra-archive option
when running in -jit-kind=orc-lazy mode.

llvm-svn: 368707
</content>
</entry>
</feed>
