Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Are there any PHP -> LLVM IR translators?

Tags:

php

llvm

I need to compile PHP source to LLVM bitcode. I've tried Raven PHP (http://code.roadsend.com/rphp) and it's able to do what i want, but the project seems to be dead. So i wanted to check for some more possible projects.

After that I found phpllvm PECL extension (http://svn.php.net/viewvc/svn/pecl/llvm/). I even have almost made it to run with trunk LLVM, but after closely looking on the code, i figured, that LLVM code is being generated only when according PHP function is being executed. Unfortunately, it's not what i want.

So i wonder, if there are more projects for translating PHP to LLVM and if not - what's the best way, from your point of view, to implement such thing?

About LLVM:

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies.

like image 806
arrowd Avatar asked Aug 11 '11 12:08

arrowd


1 Answers

You didn't say what your goal is. If it is simply better performance and easy availablity, you might consider the HipHop PHP compiler.

like image 138
Ira Baxter Avatar answered Oct 20 '22 13:10

Ira Baxter