Displaying 20 results from an estimated 11000 matches similar to: "[LLVMdev] ExecutionEngine always comes back NULL"
2013 Jan 08
0
[LLVMdev] ExecutionEngine always comes back NULL
Hi Rick,
I had the same problem last week I understand that I didn't initialized
target.
Cheers,
Manuele
Il 08/01/2013 16:08, Rick Mann ha scritto:
> I wrote a little OS X app to assemble some LLVM (human-readable) code and run it. Unfortunately, my ExecutionEngine won't create. Just comes back NULL.
>
> This is the code that builds it:
>
> http://pastebin.com/8cexgPj7
2013 Jan 08
2
[LLVMdev] ExecutionEngine always comes back NULL
Sorry I forgot to add code that I use to run code:
/* Executes the AST by running the main function */
GenericValue CodeGenContext::runCode() {
std::cout << "Running code...\n";
ExecutionEngine *ee = EngineBuilder(module).create();
vector<GenericValue> noargs;
GenericValue v = ee->runFunction(mainFunction, noargs);
std::cout << "Code was run.\n";
return v;
2013 Jan 08
0
[LLVMdev] ExecutionEngine always comes back NULL
On Jan 8, 2013, at 8:09 , Manuele Conti <manuele.conti at sirius-es.it> wrote:
> Sorry I forgot to add code that I use to run code:
> /* Executes the AST by running the main function */
> GenericValue CodeGenContext::runCode() {
> std::cout << "Running code...\n";
> ExecutionEngine *ee = EngineBuilder(module).create();
> <
> div
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:
2004 Aug 10
0
[LLVMdev] API on JIT, code snippets
Reid Spencer,
thank you for your quick responce, finally i got to my PC at home.
You wrote:
> Attached are three files: "valery.cpp" which contains your original,
> "reid.cpp" which contains corrections to most of the FIXME items and
> "diffs" which shows the differences between them. The differences
> should be instructive on what to do. You were
2004 Aug 09
5
[LLVMdev] API on JIT, code snippets
Valery,
Attached are three files: "valery.cpp" which contains your original, "reid.cpp"
which contains corrections to most of the FIXME items and "diffs" which shows
the differences between them. The differences should be instructive on what to
do. You were really, really close .. just a few details changing. The code in
"reid.cpp" compiles but I
2013 Jan 09
1
[LLVMdev] ExecutionEngine always comes back NULL
Hi Rick,
you are right!
But can you call this method EngineBuilder::setErrorStr to get creation
error?
Cheers,
Manuele
Il 08/01/2013 20:27, Rick Mann ha scritto:
> On Jan 8, 2013, at 8:09 , Manuele Conti <manuele.conti at sirius-es.it> wrote:
>
>> Sorry I forgot to add code that I use to run code:
>> /* Executes the AST by running the main function */
>>
2004 Aug 13
0
[LLVMdev] is this code really JITed and/or optimized ? ..
On Sat, 14 Aug 2004, Valery A.Khamenya wrote:
> (thanks to Reid, who gave nice advice) the fibonacci function code
> works now. Please find attached file.
>
> but... the performance is adequate, say, for byte-code
> interpretation mode and not for optimized JITing.
> fibonacci function of 35 from attached file is more
> then 100 times slower then the following code compiled
2004 Aug 13
3
[LLVMdev] is this code really JITed and/or optimized ? ..
Hi all,
(thanks to Reid, who gave nice advice) the fibonacci function code
works now. Please find attached file.
but... the performance is adequate, say, for byte-code
interpretation mode and not for optimized JITing.
fibonacci function of 35 from attached file is more
then 100 times slower then the following code compiled
with "gcc -O2" :
-----------
#include <iostream>
int
2020 Feb 24
2
segfault with HowToUseJIT
Hi!
I've started looking porting our application which uses LLVM JIT to
using LLVM 9 (9.0.1).
To begin, I tried running the HowToUseJIT.cpp (example directory)
program and it fails with a segfault:
./HowToUseJIT
We just constructed this LLVM module:
; ModuleID = 'test'
source_filename = "test"
Running foo: Segmentation fault (core dumped)
Running it through GDB:
2004 Aug 17
4
[LLVMdev] JIT API example (fibonacci)
Hi LLVMers,
the example attached I have used to prove that JIT and some visible
optimizations are really invoked.
Proved OK. I got 30% speed-up in comparison to gcc 3.3.3
on my Athlon XP 1500.
Nice.
P.S. guys, no fears, I don't plan to flood the cvs repository
with my "brilliant" examples ;)
---
Valery A.Khamenya
-------------- next part --------------
An
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
2008 Aug 19
7
[LLVMdev] Please help with LLVM C++ integration
Hi Gordon,
I wrote a small example, but while running I get an error("Tied to
execute an unknown external function"), where I am wrong?
Thanks in advance.
Kirill.
int some_test_func( int ){
std::cout << "!!!!" << std::endl;
return 8848;
}
int _tmain(int argc, _TCHAR* argv[]){
Module *M = new Module("test");
ExistingModuleProvider* MP = new
2010 Sep 28
2
[LLVMdev] ExecutionEngine::create returns 0
Hendrik Boom-2 wrote:
>
> On Tue, 10 Jun 2008 07:07:35 +0530, Mahadevan R wrote:
>
>>> Now to compare it in detail with the much smaller program I've got and
>>> maybe I'll figure out what's wrong with my call to
>>> ExecutionEngine::create.
>>
>> That call is perfectly valid, actually. It works for me when linked
>> with:
2009 Jul 25
3
[LLVMdev] Bug in ExecutionEngine::getConstantValue() -- Instruction::PtrToInt
I think I might have found a bug in the exection engine's 'constants
folding'.
Basically APInt's parameters are the wrong way round.
Line 577 for lib/ExecutionEngine/ExecutionEngine.cpp :-
case Instruction::PtrToInt: {
GenericValue GV = getConstantValue(Op0);
uint32_t PtrWidth = TD->getPointerSizeInBits();
GV.IntVal = APInt(PtrWidth,
2004 Aug 17
5
[LLVMdev] JIT API example (fibonacci)
On Tue, 17 Aug 2004, Reid Spencer wrote:
> That's pretty cute actually. Do you want this "brilliant" :) example in the cvs
> repository? I'd be happy to put it in.
Here's an idea: how about we take the ModuleMaker, Valery's previous
example, and this one and put them all in one "small examples" project?
-Chris
> Valery A.Khamenya wrote:
>
>
2008 Oct 26
2
[LLVMdev] Error while creating ExecutionEngine
Hi,
I am completely new to llvm. I am trying to build an optimization pass. I need to interpret some instructions in the pass. To begin with, I used the exact same code as HowtoUseJIT example. It compiles fine. While executing using opt, I get the following error at the point where th executionengine is created:
opt: symbol lookup error: ../../../Release/lib/Try.so: undefined symbol:
2004 Aug 13
3
[LLVMdev] is this code really JITed and/or optimized ? ..
> If it's that slow, you're probably getting the interpreter instead of the
> JIT. Try adding -print-machineinstr to the command line, or -debug, and
> see what happens. If you're not getting the JIT, try stepping through the
> LLVM program to see where it makes the execution engine and decides which
> one to use...
(thanks for quick reply)
hm, here is the part of my
2004 Aug 09
0
[LLVMdev] API on JIT, code snippets
Reid wrote:
> I have to agree with Misha on this. None of us knows "everything" about
> LLVM and as you can see, Misha responded three hours before I did :).
> Asking questions here is encouraged, so please feel free to post them on
> LLVMdev. We'll always help where we can.
well, OK :)
Please find the attachment with the first approach to
such an example i've
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