similar to: Orc JIT vs. implicit template instanciation in LLVM 8

Displaying 20 results from an estimated 4000 matches similar to: "Orc JIT vs. implicit template instanciation in LLVM 8"

2019 Sep 15
2
Orc JIT vs. implicit template instanciation in LLVM 8
Well, I agree the front end must be responsible for (not) instantiating the function templates. However the problem shows up only when JIT compiling, for some reason, and only with LLVM 8. Is there perhaps something else that needs to be done before resolving symbols, in addition to running constructors, to ensure that instantiated function templates are taken into account? Or perhaps there is
2019 Sep 16
2
Orc JIT vs. implicit template instanciation in LLVM 8
I have found the cause of our problems with implicit template instantiation, and it looks to me like a bug in Orc JIT in LLVM 8. (Perhaps Lang could confirm?) We use createLegacyLookupResolver() to create our symbol resolver, passing it a lookup function. Amongst other things, our function calls LegacyRTDyldObjectLinkingLayer::findSymbol() to look up symbols in the JIT. When a module is
2019 Sep 16
2
Orc JIT vs. implicit template instanciation in LLVM 8
No, the problem is that Finalized is true. It is set to true at the start of the finalize() method. That's why I added a test causing that line to be executed if the symbol's address is zero... On Tue, 17 Sep 2019, 00:05 Lang Hames, <lhames at gmail.com> wrote: > Hi Geoff, > > Oof. I don't know what this is yet, but I bet it's going to be awful. > Quick apology
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
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
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>
2018 Jul 14
3
debugging Orc JIT'ed code
Hi Geoff, hi Alex If you implement the GDB JIT Interface in your Orc JIT, this is in general possible (at least from the JIT's point of view) with both debuggers, GDB and LLDB. Please have a look at the example here: https://github.com/weliveindetail/JitFromScratch/tree/jit-debug/gdb-interface You will probably need to adjust the code depending on the LLVM version you are using. As described
2018 Jul 13
2
debugging Orc JIT'ed code
Greetings, LLVM wizards. I was just wondering if any progress has been made on this issue in the last few months (using gdb to debug a module compiled by Orc). I had to move to the Orc API in order to be able to call modules' constructors and destructors as needed, but I would quite like to be able to debug and profile the resulting code as well... Thanks, Geoff -------------- next part
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?
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
2020 Jan 24
4
ORC JIT Weekly #2 -- COFF COMDAT Constants and Emulated TLS
Hi All, This week I've been focused on removing some of the blockers for people transitioning from ORCv1 to ORCv2. Issue #1 (http://llvm.org/PR40074, http://llvm.org/PR44337): When LLVM codegens floating point constants for COFF we produce named constant pool entries of the form __real@<bitval>. These are stored in COFF COMDAT sections [1] which allow duplicate symbol definitions to
2018 Jun 21
2
runStaticConstructorsDestructors() causes crash on exit
When OrcMCJITReplacement is given a new module, it asks for the module's constructors, gives them names like $static_ctor.0, $static_ctor.1, etc., and saves the mangled names in a map. Later, to execute them, it uses runViaLayer(), which looks for those symbol names in the given JIT layer. Could one not simply execute the constructors straight away, rather than naming them and looking them up
2018 Jun 25
2
runStaticConstructorsDestructors() causes crash on exit
Many thanks for the sample code, Alex. In the end I did it the same way OrcMCJITReplacement does it. Constructors and destructors are called and, thanks to LocalCXXRuntimeOverrides, the program does not crash on exit! But it does seem like there should be a simpler way; the learning curve is steep... Geoff On Thu, 21 Jun 2018 at 12:28, Alex Denisov <1101.debian at gmail.com> wrote: >
2018 Jun 19
2
runStaticConstructorsDestructors() causes crash on exit
On Alex's advice I am switching from MCJIT to the Orc API to compile and execute functions. Starting from the new clang-interpreter example in the source code (top of the tree!), I am able to execute my functions all right... as long as there are no constructors and destructors to call. My question: is there a simple way, with the Orc API, to run a module's constructors and destructors? I
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
4
LLJIT vs. thread-local storage
I am in the process of porting our ORC code to ORC v2 and LLJIT. Now that I have worked around a problem getting global constructors to be called, everything seems to work unless a module declares a static thread-local variable. In that case I get a "JIT session error" saying that the symbol __ emutls_v.xyz was not found (substitute the mangled variable name for "xyz"). Does
2020 Aug 10
2
[EXTERNAL] Re: Orc JIT v2 breaks OpenMP in 11.x branch?
Yeah, I remember encountering that error before when getting it to pass the libomp test suite. If you have a struct named "ident_t" somewhere the compiler will rename it because of the conflict with the runtime declaration. This should be solved by casting the usage to the function type found in the definition (i.e. bitcasting a struct.ident_t.21 to struct.ident_t) which solved the
2020 Sep 28
2
LLJIT vs. thread-local storage (again)
Hmm, I'm confused. The DSO is compiled with gcc. Do I need to compile it with clang instead? I don't believe the JITted code uses the thread support library directly, although I suppose it may be hidden with templates and/or inline functions... On Mon, Sep 28, 2020 at 10:43 PM Lang Hames <lhames at gmail.com> wrote: > > Hi Geoff, > > If you want to access the variable
2020 Aug 10
2
[EXTERNAL] Re: Orc JIT v2 breaks OpenMP in 11.x branch?
Yep, it happens three times, then crashes afterwards, since I removed the assert... arg 0: expected %struct.ident_t* got %struct.ident_t.21* value @0 = private unnamed_addr global %struct.ident_t.21 { i32 0, i32 514, i32 0, i32 0, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str, i32 0, i32 0) }, align 8 arg 0: expected %struct.ident_t* got %struct.ident_t.21* value @1 = private
2020 Aug 10
2
[EXTERNAL] Re: Orc JIT v2 breaks OpenMP in 11.x branch?
Thanks, Joseph and Johannes. I have not merged in anything, I am using the code from the repository as is. What is this -debug-only option, and to whom would I pass it? I am running our own JIT application, which uses clang to compile modules on the fly via clang::CompilerInstance::ExecuteAction(). Working on the assumption that there is a mismatch in the declared type of an OpenMP runtime