Live data from Hacker News

HipHop VM: now at 98.5% PHP framework parity, 16% faster

hhvm.com

11–20 of 112 posts

Re: HipHop VM: now at 98.5% PHP framework parity, 16% faster

#11
post #7

With the recent discussion on the origins of PHP function names, and about what, if anything, can be done to fix PHP without ruining it...I'm curious about what happens at Facebook. Besides HipHop, do they maintain a strict PHP style among their developers? Even if HipHop can handle all of PHPs variations, I imagine there's time saved by writing optimally-designed (for the human) code, too?

Yes, they have a static analyser for PHP, Hack, written in OCaml

http://www.youtube.com/watch?v=gKWNjFagR9k

Re: HipHop VM: now at 98.5% PHP framework parity, 16% faster

#12
post #7

With the recent discussion on the origins of PHP function names, and about what, if anything, can be done to fix PHP without ruining it...I'm curious about what happens at Facebook. Besides HipHop, do they maintain a strict PHP style among their developers? Even if HipHop can handle all of PHPs variations, I imagine there's time saved by writing optimally-designed (for the human) code, too?

For core language features like that, there really is no way to "fix" it. Just pick a better language.

Re: HipHop VM: now at 98.5% PHP framework parity, 16% faster

#13
post #8

What does a Lockdown implies?

I'm not sure about the particulars of this one, but a lockdown is generally a period where you are encouraged to prune away unnecessary and/or lower-priority requests for your time.

There generally aren't a lot of status meetings, team meetings, project meetings, and so forth at Facebook, but you might want to turn down a request to present at another team's meeting, or turn down those requests to interview - they can wait, or another person can be found.

People tend to make progress on lower-priority work items in between higher-priority work items - things like migrating onto a new library or version of a service, or maybe migrating from one set of machines to another if you aren't using one of the high-level service management systems. This is necessary to prevent these things from becoming interrupt items down the line, but during a lockdown period, it's okay to let these slide for a bit.

If the whole team does this, then suddenly you're spending a lot more time together. Instead of potentially working on different parts of the software like you usually do, you can all focus on a particular class of problem - in this case, performance and parity. That means everyone has that context loaded up, and you can have better discussions and quicker code reviews.

Re: HipHop VM: now at 98.5% PHP framework parity, 16% faster

#14
post #7

With the recent discussion on the origins of PHP function names, and about what, if anything, can be done to fix PHP without ruining it...I'm curious about what happens at Facebook. Besides HipHop, do they maintain a strict PHP style among their developers? Even if HipHop can handle all of PHPs variations, I imagine there's time saved by writing optimally-designed (for the human) code, too?

Code style is enforced (but overridable) by the code review system - both automated tools that provide feedback ("lint") on the code (things like "Don't use funcx() - it sucks - rather use funcy()"), and human code review.

Re: HipHop VM: now at 98.5% PHP framework parity, 16% faster

#16
post #13
post #8

What does a Lockdown implies?

I'm not sure about the particulars of this one, but a lockdown is generally a period where you are encouraged to prune away unnecessary and/or lower-priority requests for your time. There generally aren't a lot of status meetings, team meetings, project meetings, and so forth at Facebook, but you might want to turn down a request to present at another team's meeting, or turn down those requests to interview - they ca…

[deleted]

Re: HipHop VM: now at 98.5% PHP framework parity, 16% faster

#18
post #10

Earlier quoted context omitted.

HipHop was the PHP -> C++ compiler. HHVM is a JIT-compiled implementation of PHP. The 15% increase is relative to HHVM at the beginning of the 3-week sprint they just completed. HHVM was already far faster than vanilla PHP when it was first publicly announced over a year ago.

That's more interesting. How much faster is hhvm overall?

The Wikipedia article (https://en.wikipedia.org/wiki/HipHop_for_PHP) says "up to 6x", however, about 2x speedup versus plain PHP was a more typical experience for me when I used it before.

Re: HipHop VM: now at 98.5% PHP framework parity, 16% faster

#20

Other than Facebook, does anybody have HipHop running in production? Any big caveats?

I run HHVM on a website. I started in June (back then you had to write your config file from scratch and some API functions were missing). I refactored my code to PDO (mysqli was missing back then). It worked fine from the beginning, and the uptime and overall performance is really great.

I use Nginx as frontend and direct all dynamic request to HHVM's own webserver (https://github.com/facebook/hhvm/wiki/Using-nginx-as-Front-S... )

Keep in mind, Facebook runs on HHVM too, so it's rock solid.

Btw. the devs are very helpful on the official irc channel!

Post reply on HN