3 ms·
You could also write your software in assembly and it'll be faster than all of those you mentioned. The point is to select a language that is feasible for a bus
by maratd 15y ago
You could also write your software in assembly and it'll be faster than all of those you mentioned. The point is to select a language that is feasible for a business. Facebook is not an academic exercise. PHP has a lower barrier to entry, which in practical terms reduces the wages that need to be paid. You then get a few guys who are great at C (PHP is written in C) and fix whatever parts are getting in the way of great performance. Which is exactly what Facebook is doing. Remember, Facebook is a business.
- jasonlotito 15y agoYou're getting downvoted by people who disagree with you, not because you aren't contributing to the discussion. I just wanted to make it clear that they are wrong for doing that, and that your comment, whether I agree or not, is appreciated.
- fleitz 15y agoFully agree, given the code base that exists the best ROI likely comes from improving execution speed of PHP rather than rewriting the codebase.
- jrockway 15y agoMaybe if it's a video decoder that uses special video decoding instructions. For real world code, though, a good JIT is going to make most code very fast, and you will actually be able to maintain it. I don't think Java is any harder to maintain than PHP, but it runs much faster. (I think Perl and Python are much easier to maintain, however, so if that was what we were arguing about, then it would make sense. PHP is objectively the worst "P" language.)
- maratd 15y agoYou're missing my point so completely that it becomes a fine example of why engineers make poor businessmen. The best business solution is the one that accomplishes the task at hand with the least resources. By that metric, PHP is far superior to Java, regardless of the technical merits at hand. It costs less to hire an army of PHP devs and a small team to optimize PHP, than it does to hire an army of Java developers. http://www.payscale.com/research/US/Job=PHP_Developer/Salary http://www.payscale.com/research/US/Job=PHP_Developer/Salary and http://www.payscale.com/research/US/Job=Java_Developer/Salary http://www.payscale.com/research/US/Job=Java_Developer/Salar... The difference in pay is around $20K. If you have 500 developers, that's a difference of $10 mil per year. Over the span of a decade, you're talking about over $100 million in savings. As I said, Facebook is a business, not a pet project or an academic exercise. Decisions on which platform to use and keep are made based on dollars and cents ... not on which is more elegant or technically superior.
- dhugiaskmak 15y ago> It costs less to hire an army of PHP devs and a small team to optimize PHP, than it does to hire an army of Java developers. Is that what Facebook is doing? Everything I've read about interviewing and getting hired at Facebook leads me to believe that they are not hiring an army of cheap PHP developers.
- ranit8 15y agoEdit: to avoid a totally uninformative comment, as I see no links to previous discussions, this one: http://news.ycombinator.com/item?id=3335217 http://news.ycombinator.com/item?id=3335217 The 2 URLs in the parent show the limit at which adding ellipsis sometimes make the inner text of links longer instead of shorter.
- lngjmp 15y agoYou are right. What you say is accurate. And it is an objective observation. Ignore the downvotes. They might be coming from Facebook employees (it's obvious they read HN and apparently they feel the need to defend FB's choices) and other PHP coders who do not know/like the other faster languages you mentioned. Quite silly.
- tikhonj 15y agoMy impression is that Facebook has plenty of people who would not find learning Haskell, OCaml or Lisp particularly difficult, and would thereafter be more productive than in PHP. In fact, I know for a fact that some of their internal tools are written in Haskell and some variant of ML. If there is any company that should not be worried about a language's barrier to entry or trying to get cheap programmers, it's Facebook--my impression is that they have an engineering team more like Google than your favorite nameless corporation. I think what Facebook is doing is working with a ton of legacy PHP code. In fact, from what I've heard, they're definitely open to using other languages in new projects; it's just that rewriting all the PHP code they already have would be horribly wasteful.