[LLVMdev] Scheme + LLVM JIT

Chris Lattner sabre at nondot.org
Mon May 16 21:46:38 PDT 2005


On Tue, 17 May 2005, Alexander Friedman wrote:
> On May 16, Chris Lattner wrote:
>>> This seems reasonable, but what happens to the users of the module if
>>> it were to be updated - for example, if I load said module in the jit,
>>> and then add something to it.
>>
>> This should be fine.  The JIT won't touch a function until it is called.
>
> What if you read in a function with the same signature? Will it just
> replace it?

No, the caller will have to be careful to remove the body of the old 
function from the module.  The asmparser should be fine with pre-existing 
prototypes though.

>>> I *could* build everything as a shared library, and include everything
>>> on the command line that way, but that seems a bit errorprone, not to
>>> mention the fact that building everything with PIC takes ~3x longer.
>>
>> This should be possible, though our current makefile system is not going
>> to do this automatically right now.
>
> Can I add submit a patch to do something like this  (if it doesn't
> disturb the makefile system that much)?

In the abstract, yes, of course :)  I'll let Reid deal with the details 
though :)

> Maybe if one is building a library and sets a "LINK_IN_LIBS" flag or
> something? I am guessing there might be other people that want
> something like this - ie, anybody building a shared library that they
> want to use in another application.

Makes sense to me!

-Chris

-- 
http://nondot.org/sabre/
http://llvm.cs.uiuc.edu/




More information about the llvm-dev mailing list