[llvm-commits] [PATCH] Add basic ELF Dyld loader (on behalf of Andy Kaylor)

Rafael Ávila de Espíndola rafael.espindola at gmail.com
Thu Dec 22 05:54:55 PST 2011


On 19/12/11 03:16 PM, Malea, Daniel wrote:
> Hi all,
> 
> Thanks everyone for your input; here's an updated patch with passing tests! In addition to running the existing ExecutionEngine tests against MCJIT, we added a few new test cases. To run them against the MCJIT implementation, invoke lit with the "--param jit_impl=mcjit" option, which then causes lli to be invoked with "-use-mcjit".
> 
> Compared to the last iteration of the patch, here’s exactly what has changed:
> -	Removed "default:" case in switch statement as per Rafael’s suggestion
> -	Moved RuntimeDyldMachO::isKnownFormat() into isCompatibleFormat() of the same class
> -	Added 6 new test cases in test/ExecutionEngine
> -	Added “XFAIL: mcjit” to tests we expect not to pass 
> -	Updated lit.cfg and existing ExecutionEngine tests to handle the jit_impl parameter
> -	Updated lli to use the default memory manager (to enable MCJIT to even run)
> -	Removed Objective-C specific name handling behavior from the MCJIT memory manager
> 
> Regarding the last point, I'm not really confident that just removing the objective-c specific behavior is correct, but it seems like language specific things should probably not go in something called "MCJITMemoryManager". Perhaps Jim Grosbach can comment as he is on the commit logs for the code being touched. Maybe we should rename the existing implementation to something like ObjCMCJITMemoryManager?
> 
> Regarding the tests, the code isn't quite robust enough to enable all the existing ExecutionEngine tests to pass due to known issues with external function calls and globals; but nonetheless the following existing tests do pass, at least on (Ubuntu) Linux ia64:
> 

This is really cool!

You might be able to say "%lli" instead of "lli %jit_impl", similar to
what we do with %clang_cc1

I will let Jim do the final review as he knows that code better.

Cheers,
Rafael



More information about the llvm-commits mailing list