Personal View site logo
Make sure to join PV on Telegram or Facebook! Perfect to keep up with community on your smartphone.
Please, support PV!
It allows to keep PV going, with more focus towards AI, but keeping be one of the few truly independent places.
HipHop VM by Facebook
  • HipHop VM (HHVM) is a new open-source virtual machine designed for executing programs written in PHP. HHVM uses a just-in-time compilation approach to achieve superior performance while maintaining the flexibility that PHP developers are accustomed to. HipHop VM (and older versions of HipHop before it) has realized > 5x increase in throughput for Facebook compared with Zend PHP 5.2

    Links:

    http://www.facebook.com/hphp

    https://github.com/facebook/hiphop-php

    http://www.hiphop-php.com/wp/

  • 6 Replies sorted by
  • It sounds something like Google's App Engine (GAE) but in PHP.

  • It sounds something like Google's App Engine (GAE) but in PHP

    Whole point here that it is for PHP :-) And it replaced their PHP to C++ to binary approach.

  • A good explanation of this latest Virtual Machine implementation of HipHop-PHP is found at PC World:

    Firstly:

    Facebook originally devised a compiler, called HipHop, that would translate PHP code into C++, so it then it could be compiled ahead of time for faster performance.

    See http://en.wikipedia.org/wiki/HipHop_for_PHP

    Now:

    Virtual system speedier

    ...HHVM actually works on the same principle as the Java Virtual Machine (JVM). HHVM has a just-in-time (JIT) compiler that converts the human readable source code into machine-readable byte code when it is needed.

    ....about twice as fast as HPHPc was, and about nine times as fast as running straight PHP.

    http://www.pcworld.com/article/2045353/facebook-invents-a-php-virtual-machine.html

  • PHP and JIT... haha why not. Even Javascript has JIT engine in major web browsers.

    Facebook, Google, Apache Group... they are doing some fun stuffs nowadays.

  • @stonebat

    Problem with PHP is not speed only, but whole design. You can go back in blog post to get post about it.

    They are doing it because you can get plenty of cheap PHP developers and no need to rewrite large code base.

  • Well... programmers have become commodity for sure...