Live data from Hacker News

Speeding up PHP with the HipHop VM

facebook.com

21–30 of 122 posts

Re: Speeding up PHP with the HipHop VM

#21
post #16

Earlier quoted context omitted.

I think you underestimate the number of PHP developers out there. There aren't many on Hacker News because we're all too cool for that stuff, but in the developer world in general there are a ton.

I think his point is that real top-tier developers are going to despite working with such a grotty language as PHP, so it hurts their hiring process that way. Whereas if they worked in a superior language (an ML, Haskell, a LISP...) they'd attract talent. Who wants to deal with a language such such inane design decisions all day? I'd imagine people signing up to work at FB do so despite the fact they use PHP, not bec…

I don't know, working on HHVM certainly seems interesting enough to attract good developers.

Re: Speeding up PHP with the HipHop VM

#22
post #13

Will FB ever invest and move off PHP? Hiring talent at FB has to be getting harder and PHP probably isn't helping.

PHP is used for a subset of development at Facebook. I'm not sure what the split is, but I would not be surprised if PHP is the primary language used by less than 60% of Software Engineers at Facebook. The rest code in C++, Java, Python, and then a bunch of other languages that are less used. The PHP development environment at Facebook is unlike that found at any other company I'm aware of, and common PHP pitfalls an…

re-writing the code of any big project is insane. You are going to face those walls you faced in the past - again. Using this logic you would change the whole codebase every few years.. ridiculous

Re: Speeding up PHP with the HipHop VM

#23

Will FB ever invest and move off PHP? Hiring talent at FB has to be getting harder and PHP probably isn't helping.

I'm sure having some PHP code at a company like Facebook isn't deterring any serious candidates. Working for a company with almost a billion users who've created software like Cassandra, Thrift, HipHop and Haystack and working on writing loosely coupled systems which will run across thousands of machines; analyzing 10s of PB of data every day with Hadoop, there are definitely very specific and challenging tasks which would attract tons of talent. I think having a PHP codebase there isn't indicative that your new job would be sitting and writing crappy PHP code templates all day and wanting to kill yourself because it is so boring. Just my 2c.

Re: Speeding up PHP with the HipHop VM

#25
post #16

Earlier quoted context omitted.

I think you underestimate the number of PHP developers out there. There aren't many on Hacker News because we're all too cool for that stuff, but in the developer world in general there are a ton.

I think his point is that real top-tier developers are going to despite working with such a grotty language as PHP, so it hurts their hiring process that way. Whereas if they worked in a superior language (an ML, Haskell, a LISP...) they'd attract talent. Who wants to deal with a language such such inane design decisions all day? I'd imagine people signing up to work at FB do so despite the fact they use PHP, not bec…

It's not like people who work at Facebook have to use PHP anyway - there are quite a few who work in "superior" languages, although most just use C++, Java, and Python.

In my experience, the top-tier developers enjoy challenges and solving problems, and languages are just tools they use to defeat those challenges and solve those problems. Sometimes it's a language they really enjoy using. Sometimes it's a situation where that language isn't a suitable one.

Re: Speeding up PHP with the HipHop VM

#26
post #12
post #5

Things make sense now. I remember a while back Facebook invested in an experiment with PHP on PyPy. They didn't pursue it, even though it produced impressive results. It seems their own in-house JIT has better performance?

HHVM was pretty far along when we started talking to the PyPy folks; it was already able to run the site, and hosting internal development at Facebook. Our interest in PyPy wasn't an immediate, drop-everything-and-change-to-PyPy kind of interest. It was a research project, which had a positive outcome. Making a production-ready, PyPy-based system for PHP would still be an enormously big undertaking, though. PyPy is t…

I'm kind of surprised you didn't pursue the JVM and InvokeDynamic for this purpose instead of PyPy

Re: Speeding up PHP with the HipHop VM

#27
post #12
post #5

Things make sense now. I remember a while back Facebook invested in an experiment with PHP on PyPy. They didn't pursue it, even though it produced impressive results. It seems their own in-house JIT has better performance?

HHVM was pretty far along when we started talking to the PyPy folks; it was already able to run the site, and hosting internal development at Facebook. Our interest in PyPy wasn't an immediate, drop-everything-and-change-to-PyPy kind of interest. It was a research project, which had a positive outcome. Making a production-ready, PyPy-based system for PHP would still be an enormously big undertaking, though. PyPy is t…

[deleted]

Re: Speeding up PHP with the HipHop VM

#28
post #16

Will FB ever invest and move off PHP? Hiring talent at FB has to be getting harder and PHP probably isn't helping.

I think you underestimate the number of PHP developers out there. There aren't many on Hacker News because we're all too cool for that stuff, but in the developer world in general there are a ton.

Where do you get your estimates from?

Re: Speeding up PHP with the HipHop VM

#29
By the way, there is an alternative to HipHop that is actually easier to implement because it makes php extensions.

It's called PHC http://phpcompiler.org and it's open source.

It was Paul Biggar's PhD thesis http://blog.paulbiggar.com/archive/a-rant-about-php-compiler...

It just needs some community contributions to catch up.

Re: Speeding up PHP with the HipHop VM

#30

Will FB ever invest and move off PHP? Hiring talent at FB has to be getting harder and PHP probably isn't helping.

First, it's really hard to do a large rewrite of software. Netscape, for example, made the mistake of trying to rewrite their browser from scratch, and it killed them [1].

Second, what evidence to you base your statement "hiring talent at FB has to be getting harder"? If you're talking about market cap / upside, Google has had no problems hiring (well, relative to other tech companies, anyway), despite a market cap 3.5x+ what FB is today.

Lastly, FB is not all PHP. A lot of services are written in C++ or Java, and use Thrift to talk to the frontend [2]. Thrift allows a more gradual movement off PHP, by moving isolated components to other languages individually.

[1] http://www.joelonsoftware.com/articles/fog0000000069.html [2] http://www.quora.com/Facebook-Engineering/What-is-Facebooks-...

Post reply on HN