search for: llvm_jit_global_emitter2

Displaying 8 results from an estimated 8 matches for "llvm_jit_global_emitter2".

2008 Oct 14
2
[LLVMdev] bug in the JIT global variable emitter
...JIT memory buffer. I made another one that takes keeps the allocation of global variables in the JIT buffer, but it creates a new mem block if it doesn't exist (i.e. when dumping a global variable out of the scope of a function compilation). The patch is at: http://web.ist.utl.pt/nuno.lopes/llvm_jit_global_emitter2.txt The problem only happens when calling ExecutionEngine::getPointerToGlobal(someGV) from some non-llvm program. If the function is called when JITing a function, it works, since it will dump the global variable to the memory reserved to the function being JITed, which raises a question: shou...
2008 Oct 14
2
[LLVMdev] bug in the JIT global variable emitter
...the JIT memory buffer. I made another one that takes keeps the allocation of global variables in the JIT buffer, but it creates a new mem block if it doesn't exist (i.e. when dumping a global variable out of the scope of a function compilation). The patch is at: http://web.ist.utl.pt/nuno.lopes/llvm_jit_global_emitter2.txt The problem only happens when calling ExecutionEngine::getPointerToGlobal(someGV) from some non-llvm program. If the function is called when JITing a function, it works, since it will dump the global variable to the memory reserved to the function being JITed, which raises a question: shouldn&...
2008 Oct 15
0
[LLVMdev] bug in the JIT global variable emitter
...that takes keeps the allocation of global > variables in > the JIT buffer, but it creates a new mem block if it doesn't exist > (i.e. > when dumping a global variable out of the scope of a function > compilation). > The patch is at: > http://web.ist.utl.pt/nuno.lopes/llvm_jit_global_emitter2.txt OK, I think I finally understand this: the allocation in JIT::getOrEmitGlobalVariable doesn't call into JITEmitter but uses the MachineCodeEmitter directly. Thus, if you call it from outside the JITEmitter, it won't update the data structures the JITEmitter relies on. In th...
2008 Oct 16
2
[LLVMdev] bug in the JIT global variable emitter
...allocation of global >> variables in >> the JIT buffer, but it creates a new mem block if it doesn't exist >> (i.e. >> when dumping a global variable out of the scope of a function >> compilation). >> The patch is at: >> http://web.ist.utl.pt/nuno.lopes/llvm_jit_global_emitter2.txt > > OK, I think I finally understand this: the allocation in > JIT::getOrEmitGlobalVariable doesn't call into JITEmitter but uses the > MachineCodeEmitter directly. Thus, if you call it from outside the > JITEmitter, it won't update the data structures the JITEmitter re...
2008 Oct 13
0
[LLVMdev] bug in the JIT global variable emitter
On Oct 13, 2008, at 2:42 PMPDT, Nuno Lopes wrote: > Hi, > > Today I found a nice bug in the JIT global variable emitter. > The problem may lead to an assert() failure when doing the following: > 1) compile some function > 2) emit a global variable > 3) compile another function. an assert() may trigger in the JIT memory > manager > > This happens because the JIT
2008 Oct 15
0
[LLVMdev] bug in the JIT global variable emitter
...that takes keeps the allocation of global > variables in > the JIT buffer, but it creates a new mem block if it doesn't exist > (i.e. > when dumping a global variable out of the scope of a function > compilation). > The patch is at: > http://web.ist.utl.pt/nuno.lopes/llvm_jit_global_emitter2.txt Sorry, I am still not able to understand the problem. Is there a bug in the default memory manager? From your patch it seems like there is a real bug. What is the assertion that you ran into? > > > The problem only happens when calling > ExecutionEngine::getPointerToGlobal(som...
2008 Oct 13
4
[LLVMdev] bug in the JIT global variable emitter
Hi, Today I found a nice bug in the JIT global variable emitter. The problem may lead to an assert() failure when doing the following: 1) compile some function 2) emit a global variable 3) compile another function. an assert() may trigger in the JIT memory manager This happens because the JIT global variable emitter is using the MachineCodeEmitter::allocate() function, which uses memory
2008 Oct 16
0
[LLVMdev] bug in the JIT global variable emitter
...;> variables in >>> the JIT buffer, but it creates a new mem block if it doesn't exist >>> (i.e. >>> when dumping a global variable out of the scope of a function >>> compilation). >>> The patch is at: >>> http://web.ist.utl.pt/nuno.lopes/llvm_jit_global_emitter2.txt >> >> OK, I think I finally understand this: the allocation in >> JIT::getOrEmitGlobalVariable doesn't call into JITEmitter but uses >> the >> MachineCodeEmitter directly. Thus, if you call it from outside the >> JITEmitter, it won't update the da...