Displaying 20 results from an estimated 20000 matches similar to: "[LLVMdev] transitions from C code to LLVM JIT code and back"
2007 Oct 15
0
[LLVMdev] transitions from C code to LLVM JIT code and back
> What I have not seen an example of, and want to know if it's
> possible, is having LLVM generated code calling back out to plain C
> code during its run.
When I was first looking at LLVM, I googled a lot, and found somebody
saying to do it this way:
http://onesadcookie.com/trac/browser/AbandonedExperiments/Argh/CodeGen.g
(lines 43-51). I'm pretty sure now though that
2019 Aug 27
4
Orc JIT vs. STL
Greetings, LLVM wizards.
We are using Clang and Orc JIT (v1) to compile and execute C++ code on the
fly. If a C++ module calls functions from external libraries, we add them
via DynamicLibrary::LoadLibraryPermanently().
The problem we have run into recently is when a module calls a function
from the STL -- in particular this swap() function for input streams:
#include <fstream>
2019 Aug 27
2
Orc JIT vs. STL
You can add symbols from Archieve via StaticLibrarySearchGenerator. But it
is added recently though
On Tue, 27 Aug 2019 at 21:02, Praveen Velliengiri <
praveenvelliengiri at gmail.com> wrote:
> Hi Geoff,
> I tried it, but I can't able to reproduce it.
>
> Test Program:
> #include <fstream>
> int main()
> {
> std::ifstream stream1, stream2;
>
2019 Aug 27
2
Orc JIT vs. STL
On Tue, Aug 27, 2019 at 4:56 PM Praveen Velliengiri
<praveenvelliengiri at gmail.com> wrote:
>
> HI
> Did you run the static constructor and destructor? How did you make your process symbols visible to ORC jit?
Yes. It's the constructor that generates the undefined symbol error.
We use DynamicLibrary::LoadLibraryPermanently(nullptr) to add process
symbols.
> Could you
2013 Oct 06
1
[LLVMdev] how to runtime link to shared library symbols in the JIT?
I would like to load shared libraries at runtime for use in some JIT'd
code. I can't find much about how the JIT resolves symbols, so can
somebody answer a few questions for me?
1. Will the symbols from a dlopen'd library with RTLD_GLOBAL be
available? In this case I can manually dlopen the libraries prior to the
JIT run.
2. Can I derive from ExecutionEngine and override the
2016 May 19
2
External function resolution: MCJIT vs ORC JIT
Thanks so much! This seems to do the trick. I would have spun my wheels for a long time before discovering all of this, wow.
Do I even want to know what additional chickens need to be sacrificed to get this to work on Windows?
-- lg
> On May 18, 2016, at 1:52 PM, Lang Hames <lhames at gmail.com> wrote:
>
> Hi Larry,
>
> You're basically there, but you're hitting
2012 Apr 29
1
[LLVMdev] Running LLVM JIT on qemu-system-arm
Hi all,
I'm struggling to get lli work on qemu-system-arm. I already boot the system
with a debian squeeze rootfs which contains a statically cross-compiled lli
for armel. When I run ./lli hello.bc, I got the following error msg:
./lli: error creating EE: /lib/: cannot read file data: Is a directory
afaik, this error is related to lli using dlopen() with a NULL path to
resolve symbols for
2016 May 20
0
External function resolution: MCJIT vs ORC JIT
Hi Larry,
Thanks so much! This seems to do the trick. I would have spun my wheels for
> a long time before discovering all of this, wow.
No worries. :)
I'll try to keep this in mind and make sure I address it in future
Kaleidoscope tutorial chapters - these issues tripped me up the first time
I encountered them too.
Do I even want to know what additional chickens need to be sacrificed
2009 Jul 02
0
[LLVMdev] Having JIT resolve extern "C" functions declared in executible
On Jul 2, 2009, at 1:05 AM, Carter Cheng wrote:
> I am having some difficulties getting the LLVM JIT to resolve extern
> "C" functions which I have defined in source file and invoking them
> via EE::runFunction() after generating a Function prototype for it.
> Is this possible or do I need to generate a .so for my functions are
> link against it?
If the JIT needs
2009 Jul 02
3
[LLVMdev] Having JIT resolve extern "C" functions declared in executible
Hi,
I am having some difficulties getting the LLVM JIT to resolve extern "C" functions which I have defined in source file and invoking them via EE::runFunction() after generating a Function prototype for it. Is this possible or do I need to generate a .so for my functions are link against it?
Thanks in advanced,
Carter.
Sorry for the double post but apparently I mistakenly tagged
2016 May 22
1
External function resolution: MCJIT vs ORC JIT
>> llvm::sys::DynamicLibrary::LoadLibraryPermanently(nullptr)
This is one is a bit tricky and hard to find.
I spent quiet some time digging into MC and ORC JIT execution engines trying to find what makes them work.
The problem is that this trick (LoadLibraryPermanently) happens inside of EngineBuilder, despite that the functionality belongs to a JIT engine itself, not to the builder.
I
2013 Jan 09
3
[LLVMdev] ExecutionEngine always comes back NULL
On Jan 8, 2013, at 13:55 , "Kaylor, Andrew" <andrew.kaylor at intel.com> wrote:
> You need to include 'llvm/ExecutionEngine/JIT.h' (or 'llvm/ExecutionEngine/JIT.h' if you want that engine) from your main file. Including that file forces the JIT static constructor to be linked into your executable. Without it, the JIT static constructor gets optimized out and
2016 May 17
3
External function resolution: MCJIT vs ORC JIT
When using ORC JIT, I'm having trouble with external function resolution (that is, of a function defined in the app, with C linkage).
I add a declaration for the function to my IR, and when I use MCJIT, it finds it and all is well, But when I use ORC JIT (I *think* correctly, at least it closely matches what I see in the tutorial), I get an LLVM error, "Program used external function
2011 Jun 21
1
[LLVMdev] Instantiating a JIT on win64
hi all,
I'm trying to write an LLVM-based interpreter for a small DSL that we have.
The language is very simple (essentially a calculator), but I'd like it to
execute efficiently. I've been following the tutorial, and have the
following code for instantiating an ExecutionEngine:
#include <LLVM\ExecutionEngine\JIT.h>
#include
2019 Dec 20
2
LLJIT vs. thread-local storage
Argh. Thanks for the info. We're on Linux.
On Fri, Dec 20, 2019 at 3:46 PM Praveen Velliengiri <
praveenvelliengiri at gmail.com> wrote:
> Hi Geoff,
> Gathering from past, I remember that the ORCv2 doesn't support thread
> local variable but not sure what is the current status now. What platform
> you are on?
> CC'ed (Lang hames) he knows exactly what is the
2019 Dec 20
2
LLJIT vs. thread-local storage
Yes, I confirm.
Le ven. 20 déc. 2019 à 19:12, Praveen Velliengiri <
praveenvelliengiri at gmail.com> a écrit :
> Hi,
> Orc v2 is different from the internal structure then Orc v1 not just in
> API level.
> TLS support is not in ORC for a long time at least I'm aware of , Could
> you please confirm that ORC v1 actually compiles and run the code with
> Thread locals?
2013 Jan 09
0
[LLVMdev] ExecutionEngine always comes back NULL
Rick Mann <rmann at latencyzero.com> writes:
> On Jan 8, 2013, at 13:55 , "Kaylor, Andrew" <andrew.kaylor at intel.com> wrote:
>
>> You need to include 'llvm/ExecutionEngine/JIT.h' (or
>> llvm/ExecutionEngine/JIT.h' if you want that engine) from your main
>> file. Including that file forces the JIT static constructor to be
>> linked
2019 Dec 20
2
LLJIT vs. thread-local storage
And yet the same C++ code using thread-local variables works fine (or seems
to) when compiled with Orc v1. Does the change to the Orc API really make
thread-local storage more difficult?
On Fri, Dec 20, 2019 at 3:52 PM Praveen Velliengiri <
praveenvelliengiri at gmail.com> wrote:
> Oh, I think Linux don't have support for TLS.
>
> On Fri, 20 Dec 2019 at 20:19, Geoff Levner
2018 Nov 05
2
ORC JIT api, object files and stackmaps
Hi Christian
Your use case seems to have similar requirements as remote JITing in
ORC. So far I haven't used that part myself and I am sure Lang can tell
you much more about it. However, this comment on the
RemoteObjectClientLayer class sounds promising for your questions (1)
and (2):
/// Sending relocatable objects to the server (rather than fully relocated
/// bits) allows JIT'd code
2013 Jan 08
0
[LLVMdev] ExecutionEngine always comes back NULL
Hi Rick,
You need to include 'llvm/ExecutionEngine/JIT.h' (or 'llvm/ExecutionEngine/JIT.h' if you want that engine) from your main file. Including that file forces the JIT static constructor to be linked into your executable. Without it, the JIT static constructor gets optimized out and you get the result you're seeing.
-Andy
-----Original Message-----
From: