[LLVMdev] Strange LLVM Crash

Nyx mcheva at cs.mcgill.ca
Sat Mar 14 09:32:17 PDT 2009


Valgrind seems to not like the Boehm's GC and cause a seg fault of its own
before I can even test anything.

Anyways, I don't see how I could be causing "memory corruption". If I do
something wrong, it has to be some kind of unintended use of the LLVM API.
I'm definitely not writing data into the LLVM function objects myself. Could
LLVM be deleting those objects is the question I'm basically asking.

- Maxime


Duncan Sands wrote:
> 
> Hi Nyx,
> 
>> I'm implementing a JIT and getting some strange crashes. I'm unsure
>> exactly
>> what's causing them, but it seems to occur when I call the
>> getReturnType()
>> method on some LLVM function objects. More precisely, I'm registering
>> some
>> native C++ functions as LLVM functions through the addGlobalMapping
>> method
>> of an execution engine object. I then keep a pointer to those LLVM
>> function
>> objects, which I use later on to create call instructions to those native
>> C++ functions.
> 
> sounds like memory corruption to me.  Try running under valgrind.
> 
> Ciao,
> 
> Duncan.
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
> 
> 

-- 
View this message in context: http://www.nabble.com/Strange-LLVM-Crash-tp22508882p22514378.html
Sent from the LLVM - Dev mailing list archive at Nabble.com.




More information about the llvm-dev mailing list