Displaying 20 results from an estimated 1000 matches similar to: ""Freeing" functions generated with SimpleORC for JIT use-case"
2019 Sep 19
3
"corrupted size vs. prev_size" when calling ExecutionSession::lookup()
Hi, I wrote a compiler that generate IR code and run it on the JIT, and
there randomly crashed due to "corrupted size vs. prev_size" depends on the
IR code generated from the source code.
Here's how I created the JIT:
llvm::InitializeNativeTarget();
llvm::InitializeNativeTargetAsmPrinter();
llvm::InitializeNativeTargetAsmParser();
// create jit
llvm::orc::ExecutionSession
2017 Apr 09
2
Possible stack corruption during call to JITSymbol::getAddress()
Firstly, apologies if this is not the right place to be asking this
question--feel free to point me in the correct direction. I could be doing
something wrong here but stackoverflow didn't feel like the correct place
for this since there's so little there about LLVM ORC.
Basically, I have a reproduction case (below) where if I throw an exception
before I call JITSymbol::getAddress()
2019 May 10
2
ORC - which example code?
Trying to put together a simple test JIT compiler, using ORC which as I
understand it will be the supported API going forward, I noticed that in
the first chapter of the updated Kaleidoscope tutorial, there is sample
code that starts like this:
ExecutionSession ES;
RTDyldObjectLinkingLayer ObjectLayer;
IRCompileLayer CompileLayer;
DataLayout DL;
MangleAndInterner Mangle;
ThreadSafeContext Ctx;
2017 Apr 17
2
Possible stack corruption during call to JITSymbol::getAddress()
Hi David,
This looks like bad eh-frame data due to a failure to fix up the frame
descriptor entries:
<debug: adding frame> EHFrameAddr: 0x7feae5827000, EHFrameLoadAddr:
0x00000000e5827000, EHFrameSize: 60
==64588==ERROR: AddressSanitizer: SEGV on unknown address 0x7feae5827020
(pc 0x7feae886d970 bp 0x000000000001 sp 0x7ffca10e75f8 T0)
Eyeballing the code in RuntimeDyldELF (vs
2017 Nov 14
1
OrcJIT + CUDA Prototype for Cling
Hi Lang,
thank You very much. I've used Your code and the creating of the object
file works. I think the problem is after creating the object file. When
I link the object file with ld I get an executable, which is working right.
After changing the clang and llvm libraries from the package control
version (.deb) to a own compiled version with debug options, I get an
assert() fault.
In
void
2017 Sep 27
2
OrcJIT + CUDA Prototype for Cling
Dear LLVM-Developers and Vinod Grover,
we are trying to extend the cling C++ interpreter
(https://github.com/root-project/cling) with CUDA functionality for
Nvidia GPUs.
I already developed a prototype based on OrcJIT and am seeking for
feedback. I am currently a stuck with a runtime issue, on which my
interpreter prototype fails to execute kernels with a CUDA runtime error.
=== How to use the
2017 Apr 20
2
Possible stack corruption during call to JITSymbol::getAddress()
Hi David,
Thanks very much for that. I'll continue to dig in as time permits, and
I'll update the bug report with my progress once it's filed.
Cheers,
Lang.
On Mon, Apr 17, 2017 at 6:42 PM, David Lurton <dlurton at gmail.com> wrote:
> Thanks Lang. I think I'll go the bug creation route. I have an email out
> to llvm-admin requesting an account on bugs.llvm.org.
2015 Mar 13
4
[LLVMdev] Thoughts about ExecutionEngine/MCJIT interface
Hi,
I think ExecutionEngine as a common interface for both Interpreter and
MCJIT is almost useless in the current form. There are separated methods in
ExecutionEngine for similar or the same features provided by Interpreter
and MCJIT, i.e. to get a pointer to function you should call
getPointerToFunction() for Interpreter or getFunctionAddress() for MCJIT.
Personally, I'm using MCJIT and
2017 May 01
1
Possible stack corruption during call to JITSymbol::getAddress()
Hi David,
Sorry to hear. Has anyone followed up with you yet?
I've continued to dig in to this in my spare time and I've found the issue.
It's a use-after-free, rather than any sort of memory smashing. ORC is
currently failing to deregister the EH-frame section when the JIT is torn
down (but *is* deallocating the memory for it). Normally that's not
disastrous (though it does
2019 Jul 18
2
Eager compilation and relocatable dynamic linkable code-generation
Hi all,
I am following the LLVM JIT tutorial API based on:
https://llvm.org/docs/tutorial/BuildingAJIT1.html
I have 2 independent questions:
1. The tutorial mentions that "*will defer compilation of the module until
any of its definitions is looked up*".
Does that mean to force eager compilation, i have to keep track of all
functions added to the Module and do a lookup? I want the
2019 Aug 19
3
[ORC] Removing / replacing JITDylibs
Hi,
I'm working on a runtime autotuner that utilizes ORCv2 JIT (I'm closely tracking
tip-of-tree), so linking new object files and patching in the new function(s)
will happen frequently.
One of the concerns my runtime system has is the ability to do one of the
following: (1) replacement of the contents of a JITDylib with a new object file
[to provide semi-space GC-style reclaiming], (2)
2017 Aug 06
2
Compile issues with LLVM ORC JIT
I tree to compile the LLVM ORC JIT examples. But I'm stuck in some
problems I can't solve my own.
First at all I compile with C++14 enabled with latest stable LLVM and
clang, this means 4.0.1. I get the following error. Do I missed some
specific compile option?
Compilation looks like this here.
|CompilingcontribJIT.cpp
PWD:/home/ikuehl/projects-llvm/TurboLisp/domainEngineer
2017 Aug 24
1
Invalid Signature of orc::RTDyldObjectLinkingLayer::NotifyLoadedFtor
Hi all, hi Lang
It's a little late to report issues for release_50, but I just found
that thing while porting my JitFromScratch examples to 5.0.
This is a really nifty detail, but (if I'm not mistaken) the function
signature of RTDyldObjectLinkingLayer::NotifyLoadedFtor is incorrect:
$ grep -h -r -A 1 "using NotifyLoadedFtor"
2018 Jun 28
3
Since MCJIT I can't get libm functions to work
I am upgrading our JIT application to use LLVM 6.0.0, and with this
transition I am making the move to use the new MCJIT facility.
A problem I am encountering is that the math functions from libm are not
resolved/found. I am using the lambda resolver from the KaleidoscopeJIT
class which first searches the present modules and, if that is
unsuccessful, continues the search in the whole process
2017 May 07
2
[cfe-dev] JIT doens't resolve address - Resolve obj-Addresses?
Hi Bjoern,
CCing cfg-dev (since that's where the conversation started) and llvm-dev
(since it's relevant there).
Do you know if there is a way to obtain the fully resolved obj-code? I
> wanted to load the functions into a shared memory, but how? The only thing
> I receive is a function pointer, but I don't know how large the function
> 'behind' is. Even a call to
2018 Jun 28
2
Since MCJIT I can't get libm functions to work
Hi Alex,
loading the symbols explicitly helped. With this the build process
doesn't need any additional linker flags. Very nice.
Thanks,
Frank
On 06/28/2018 04:38 PM, Alex Denisov wrote:
> Hi Frank,
>
> If I am not mistaken it doesn't look in the whole process space by default.
> Please, try loading all the symbols explicitly:
>
>
2017 Feb 06
3
Kaleidoscope tutorial: comments, corrections and Windows support
Hi,
I'm currently working my way through the tutorial with LLVM 3.9.1 on
Windows (finished chapter 4) and stumbled over a few things which could
be improved:
- "LLVMContext" does not exist as a variable -> "TheContext"
- Chapter 3: 5 times
- Chapter 4: 1 time
- Chapter 5: 4 times
- Chapter 6: 2 times
- Chapter 7: 2 times
3.4. Function Code
2016 Nov 16
2
MCJit and remove module memory leak?
Hi Kevin, Koffie,
We will start migrating to ORC for next release, but for now, this release
> invoke delete after remove right?
MCJIT's removeModule method does not delete the module. You'll need to do
that manually. OrcMCJITReplacement is a bug-for-bug compatible
implementation of MCJIT using ORC components, so it does not free the
memory either.
Does this mean MCJIT is
2019 Mar 22
2
MCJIT, can't use with math functions
Hi,
for my application (uses Builder and MCJIT) I am making the transition
LLVM 6.0 -> 8.0.
It runs fine for self-contained functions, but whenever a jit-ed
function contains calls to the math library (e.g. @cosf) it seems to
have problems getting the address after successfully finding the symbol:
Failure value returned from cantFail wrapped call
UNREACHABLE executed at
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