Is LLVM useful to Squeak?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Is LLVM useful to Squeak?

askoh
Administrator
I noticed that Mono and Python are doing some work with LLVM.
http://www.mono-project.com/StudentProjects#LLVM_Back-End
http://codespeak.net/pypy/dist/pypy/doc/translation.html#the-llvm-back-end
http://llvm.org/
What are they gaining from LLVM? Can Squeak benefit from LLVM?

Thanks,
Aik-Siong Koh
Reply | Threaded
Open this post in threaded view
|

Re: [squeak-dev] Is LLVM useful to Squeak?

Igor Stasenko
2009/3/21 askoh <[hidden email]>:
>
> I noticed that Mono and Python are doing some work with LLVM.
> http://www.mono-project.com/StudentProjects#LLVM_Back-End
> http://codespeak.net/pypy/dist/pypy/doc/translation.html#the-llvm-back-end
> http://llvm.org/
> What are they gaining from LLVM? Can Squeak benefit from LLVM?
>

apart from be able to generate native code dynamically, i don't see
other use cases.
But we closing to have own native code generator in Cog.

> Thanks,
> Aik-Siong Koh
> --
> View this message in context: http://www.nabble.com/Is-LLVM-useful-to-Squeak--tp22638664p22638664.html
> Sent from the Squeak - Dev mailing list archive at Nabble.com.
>
>
>



--
Best regards,
Igor Stasenko AKA sig.

Reply | Threaded
Open this post in threaded view
|

Re: [squeak-dev] Is LLVM useful to Squeak?

johnmci
In reply to this post by askoh
Well I've done a /usr/local/bin/scan-build xcodebuild -project  
against the iPhone VM. The LLVM static analysis points out a few  
interesting things I've not really
look too hard at.

One of which is that in many places in the interpret we can end up  
with using initialized variables when the success code is false.  
However in looking at
the problem areas, if the success flag is set to false (usually not  
possible) then continuing execution is impossible anyway.

Obviously someone *could* cleanup VMMaker to ensure LLVM static  
analysis pronounces it as clean.

Now as for the compiler  getting LLVM to compile the VM is chore, and  
we know that GCC 4.2 produces a slower interpreter than 4.0. This  
after *much* work to see if we
could fool the 4.2 compiler to product code at least as good as 4.0


On 21-Mar-09, at 10:58 AM, askoh wrote:

>
> I noticed that Mono and Python are doing some work with LLVM.
> http://www.mono-project.com/StudentProjects#LLVM_Back-End
> http://codespeak.net/pypy/dist/pypy/doc/translation.html#the-llvm-back-end
> http://llvm.org/
> What are they gaining from LLVM? Can Squeak benefit from LLVM?
>
> Thanks,
> Aik-Siong Koh
> --
> View this message in context: http://www.nabble.com/Is-LLVM-useful-to-Squeak--tp22638664p22638664.html
> Sent from the Squeak - Dev mailing list archive at Nabble.com.
>
>

--
=
=
=
========================================================================
John M. McIntosh <[hidden email]>
Corporate Smalltalk Consulting Ltd.  http://www.smalltalkconsulting.com
=
=
=
========================================================================




Reply | Threaded
Open this post in threaded view
|

Re: [squeak-dev] Is LLVM useful to Squeak?

Antony Blakey-3
In reply to this post by askoh
I did some experiments integrating LLVM and CLang with VW, documented  
starting here: http://www.cincomsmalltalk.com/userblogs/antony/blogView?showComments=true&printTitle=Generating_cross-platform_high_performance_native_code_in_VisualWorks.&entry=3372121629

Yes, you can use LLVM as the code generator, probably using inlining  
to get PICs working. More immediately relevant is inline C,  
dynamically compiled and linked.


On 22/03/2009, at 4:28 AM, askoh wrote:

> I noticed that Mono and Python are doing some work with LLVM.
> http://www.mono-project.com/StudentProjects#LLVM_Back-End
> http://codespeak.net/pypy/dist/pypy/doc/translation.html#the-llvm-back-end
> http://llvm.org/
> What are they gaining from LLVM? Can Squeak benefit from LLVM?

Antony Blakey
--------------------------
CTO, Linkuistics Pty Ltd
Ph: 0438 840 787

75% of statistics are made up on the spot.