• Home
  • Technology
    • Ebullientech
    • Entrepreneurship
    • Video Technology
    • Cloud Computing
    • Business Analysis
  • Healthcare
    • Pharmacology
  • Thoughts
    • Food
    • General
    • Stories
    • Places
    • Workplace
    • Social Issues
    • Reviews
  • Quotes
  • Ebullientech News and Events
  • About

Kamalika's Notebook

thinking nothing...............!!

HipHop for PHP by Facebook

February 9, 2010 By Kamalika Leave a Comment

HipHop for PHP by FacebookOn 2nd February, 2010 Facebook announced a new project by a small team of Facebook developers who were working on for the past two years; HipHop for PHP. Facebook claims with HipHop they’ve reduced the CPU usage on their Web servers on average by about fifty percent, depending on the page and as well know less CPU means fewer number of servers, which means less overhead for high scale applications. They also claim that this project has had a tremendous impact on Facebook as it helped in reducing the huge overhead of over 400 billion PHP-based page views every month. The Web at large should benefit from HipHop but its in beta phase now so developers will have  to accommodate with it before trying it out.

According to Facebook HipHop for PHP isn’t technically a compiler itself. Rather it is a source code transformer. HipHop programmatically transforms PHP source code into highly optimized C++ and then uses g++ to compile it. HipHop executes the source code in a semantically equivalent manner and sacrifices some rarely used features — such as eval() — in exchange for improved performance. HipHop includes a code transformer, a reimplementation of PHP’s runtime system, and a rewrite of many common PHP Extensions to take advantage of these performance optimizations.

PHP belongs to the category of scripting languages and they are known to generally be less efficient when it comes to CPU and memory usage and according to Facebook:

One common way to address these inefficiencies is to rewrite the more complex parts of your PHP application directly in C++ as PHP Extensions. This largely transforms PHP into a glue language between your front end HTML and application logic in C++. From a technical perspective this works well, but drastically reduces the number of engineers who are able to work on your entire application. Learning C++ is only the first step to writing PHP Extensions, the second is understanding the Zend APIs.

Since 2007 we’ve thought about a few different ways to solve these problems and have even tried implementing a few of them. The common suggestion is to just rewrite Facebook in another language, but given the complexity and speed of development of the site this would take some time to accomplish. We’ve rewritten aspects of the Zend Engine — PHP’s internals — and contributed those patches back into the PHP project, but ultimately haven’t seen the sort of performance increases that are needed. HipHop’s benefits are nearly transparent to our development speed.

The project has taken two years: eight months to have a version that could be demonstrated, ten months finishing up all the coding, and six months testing the service on production servers and developers have written 300,000 lines of code and more than 5,000 unit tests.

The whole thing sounds very interesting and I guess it will create a buzz in millions of open sources developers but unfortunately the source code link provided by the HipHop Wiki seems broken but I’ll still follow the instructions and give it a try.

You can also check out Facebook’s video on HipHop for PHP:

Courtesy: HipHop for PHP: Move Fast

Filed Under: Facebook, Facebook Developers Tagged With: Facebook, Facebook Developers, HipHop for PHP

Let’s connect…

  • Facebook
  • Instagram
  • LinkedIn
  • Twitter
  • YouTube

Hello There…

I'm Kamalika, a techpreneur & startup mentor, blogger, hobbyist photographer, Netflix & Kindle indulgent, food connoisseur, Starbucks aficionado and former Disney employee ...next

Looking for something?

Tags

All in One SEO Pack AWS Banaras Blogger Blogging Blogs Dasaswamedh Ghat Ebullientech Ebullientech Interactive LLP Facebook Facebook Developers father's day father's day wishes father's day wishes for dad fathers day love Fathers Day Special Fathers Day wishes from daughter Father’s day memories GeoTech GeoTech Informatics HipHop for PHP Kamalika Guha Roy Kashi Ganga LAMP MySQL Nabaneeta Guha Roy Online Marketing PayPal PayPal's suspension of Indian bank transactions PHP PHP & MySQL Saraswati Puja Search Engine Optimization SEO Startup The Ganges TypePad UCO HUT Varanasi Web 2.0 Web 2.0 Design Web Design Web Marketing WordPress WordPress.COM

Timeline

  • 2021 (3)
  • 2020 (7)
  • 2019 (4)
  • 2018 (1)
  • 2015 (6)
  • 2014 (13)
  • 2013 (9)
  • 2010 (7)
  • 2009 (2)

Topics

Copyright © 2021 · Kamalika Guha Roy, Powered by: Ebullientech