PHP compilers

Original post provide by PHP Everywhere - By John Lim

The number of implementations of PHP continue to rise and rise. Among those I can list are:

  • Recently, Caucho wrote a PHP5 to Java bytecode compiler and built it into their Resin server. There’s not much information, but in the link, look for thread responses by Scott Ferguson, the compiler author.
  • The experimental Pint, a PHP to parrot compiler.
  • The commercial Roadsend PHP to binary compiler.
  • The .NET framework Phalanger, a PHP to MSIL compiler (added 22 Dec 2005).
  • The original mod_php from php.net.
  • The PHP4Mono compiler for Mono (added 27 Feb 2006).

I am excited about all these implementations. Most computationally intensive compiler benchmarks have shown a 5-10 times speedup over mod_php. Perhaps it is only a matter of time before we see a JIT compiler for PHP to Intel opcodes, built into mod_php…

A more curious question is why there has been so little takeup of these faster technologies. Some speculation here:

  • PHP is fast enough? The bottleneck is the database or the network, and not PHP?
  • PHP 4->5->6 is changing too fast to trust someone else?
  • No formal PHP specification or conformance suite makes switching more risky?
  • Not all PHP extensions or libraries are available on other platform?
  • Lack of knowledge or awareness? Or are we still in early adopter stage?
Previous Articles:
Why I Like PHP Revisited
PHP doesn't come close. I do think that Jython comes close, but it lacks the Java-style syntax required to make it really popular, and there's no one (that I know) speeding up Jython the way Jim Huginin is tuning IronPython for .NET.
Inserting Multiple Rows With One Database Call Using PHP And Oracle Collections
How to use Oracle collections to improve the efficiency of PHP scripts that feature multi-row inserts
Is PHP4 The New Perl?
The fact is that most Javascript, HTML and PHP (or ASP or Perl for that matter) out there is messy, unmaintainable crap. And that's why all the above technologies are so popular. They can be used by ordinary people with minimal training.
Yahoo! Goodies: UI Library And Design Patterns
In many cases we have bundled the patterns with pointers to related code from the Yahoo! User Interface Library. I had a look at some of the patterns. Navigation, breadcrumbs, pagination, auocompletion... Not quite what i expected: these are user interface guidelines, not coding patterns that explain ways of implementing these guidelines.
PHP Life : The Oracle
After a short break the PHP Life team are back. In this strip we look at the Zend/Oracle deal. If Oracle do buy-out Zend then let's hope things fare better for the Zend staff than Oracle staff at the moment!
More Articles:
Paris Forum 2007 : Call For Papers
For this unique event in France, we are looking for the best French speaking experts, who want to share their know-how and enthusiasm. This two day conference features one technical day, with the most advanced PHP techniques and a business day, with case studies and examples of successful projects.
Steve Yegge On Strong And Weakly Typed Languages
I think Lisp's solution, where you can add in static types as needed, is close to ideal. But I'm still a bit timid about trying to write something really significant in Ruby (my weakly-typed language of choice), on account of its performance and its lack of native threading.
Using Oracle's Built-in Security Features With PHP
How to take advantage of Oracle's native security features to improve the security of your PHP Web applications
The PHP.net Google Summer Of Code
This approach is different than code coverage analysis, because it can find code that is executed by the running of tests but not actually tested. Mentored by Sebastian Bergmann, Mike Lewis will implement Mutation Testing for PHPUnit. Mentored by Helgi Þormar Þorbjörnsson, Igor Feghali will add support for foreign keys to MDB2_Schema, a package that "enables users to maintain RDBMS independant schema files in XML that can be used to create, alter and drop database entities and insert data into a database".
ROLL YOUR OWN SEARCH ENGINE WITH ZEND_SEARCH_LUCENE
One of the features that sets the Zend Framework apart from the others is the inclusion of a decent search module. Zend_Search_Lucene is a php port of the Apache Lucene project, a full-text search engine framework. Zend_Search_Lucene promises a simple way to add search functionality to an application without requiring additional php extensions or even a database.  For more information visit: http://devzone.zend.com/node/view/id/91

Leave a Reply