PHP keepers plot radical revision of the language

Future versions of PHP may be compiled, thanks to the influence of Facebook engineers

By , IDG News Service |  Cloud Computing

Inspired by Facebook's efforts to speed performance of PHP, the core development team behind the popular open-source Web programming language has embarked on an effort to redesign PHP for faster performance.

Earlier this month, PHP core developer Dmitry Stogov started a new branch of the language called phpng (PHP Next Generation), according to a blog item posted on the PHP.net site Wednesday.

The idea behind the new version of the language is to reorganize the internal APIs (application programming interfaces) so PHP code could benefit from being used in a just-in-time (JIT) compiler.

The new phpng branch "does not include JIT capabilities, but rather seeks to solve those problems that prohibit the current, and any future implementation of a JIT capable executor achieving optimal performance by improving memory usage and cleaning up some core API's," the PHP blog post stated.

Today, PHP is an interpreted language, meaning that the source code is executed by the processor directly. Generally speaking, programs written in interpreted languages such as PHP tend not to run as quickly as languages, such as C or C++, that have been compiled beforehand into machine language byte code, which is more efficient for the processor to execute.

Last year, Facebook, which has always been a large user of PHP, released a JIT compiler for PHP code, called the HHVM (Hip Hop Virtual Machine). HHVM proved instrumental in sparking the PHP community's interest in JIT.

Similar to the Java Virtual Machine (JVM), the HHVM compiles the language into byte code when it is requested by the user. Facebook found that HHVM could speed code execution times by as much as nine times. The company released the source code of HHVM in hopes that it would be used outside of Facebook, and perhaps even influence the future development of PHP itself.

Stogov, who works as chief performance engineer at PHP software provider Zend, noted that changes already made in phpng have resulted in a 20 percent increase in the number of requests handled by WordPress, the popular blogging platform that is built on PHP.

With phpng, "the door may well now be open for a JIT capable compiler that can perform as we expect, but it's necessary to say that these changes stand strong on their own, without requiring a JIT capable compiler in the future to validate them," the blog post stated.

Join us:
Facebook

Twitter

Pinterest

Tumblr

LinkedIn

Google+

Spotlight on ...
Online Training

    Upgrade your skills and earn higher pay

    Readers to share their best tips for maximizing training dollars and getting the most out self-directed learning. Here’s what they said.

     

    Learn more

Cloud ComputingWhite Papers & Webcasts

See more White Papers | Webcasts

Answers - Powered by ITworld

ITworld Answers helps you solve problems and share expertise. Ask a question or take a crack at answering the new questions below.

Join us:
Facebook

Twitter

Pinterest

Tumblr

LinkedIn

Google+

Ask a Question