The father of PHP commented on Facebook's HipHop project: Don't use it as a silver bullet

Source: Internet
Author: User
Tags website performance
According to the New York Times website, a reporter from The read/write network contacted RasmusLerdorf, creator of PHP, and asked him about his views on Facebook's just-open-source PHP optimization project HipHop. Lerdorf said in the email that this is a cool project and will certainly become a good choice for some websites. However, for many Web applications, the execution speed

According to the New York Times website, a reporter from The read/write network contacted Rasmus Lerdorf, creator of PHP, and asked him about his views on Facebook's just-open-source PHP optimization project HipHop. Lerdorf said in the email that this is a cool project and will certainly become a good choice for some websites. However, for many Web applications, the execution speed

According to the New York Times website, a reporter from The read/write network contacted Rasmus Lerdorf, creator of PHP, and asked him about Facebook's just-open-source PHP optimization.ProjectWhat is HipHop's opinion. Lerdorf said in the email that this is a coolProject, Will certainly become a good choice for some websites.

However, for many Web applications, the execution speed is not the main factor. Even if you double the execution speed of 10% of the total request costs, the overall increase is only 5%. If you access memcache/PostgreSQL/MySQL 10 times for each request, it takes a lot of time to call the system. It is inevitable that HipHop will not be expected to bring a miracle.

Lerdorf calls HipHop code conversion programs a good trick, and worries that developers may mistakenly regard it as a magic bullet in website performance. For the new Runtime Library, Lerdorf said, it is more willing to perform basic performance analysis (profiling) to find the most useful part in the cost. It is better to accelerate or remove the slow part of the system than to accelerate the fast part of the system.

He also said that PHP's execution speed is often not the biggest problem. We should analyze all aspects of the system and find the culprit. In terms of tools, he recommended using Yahoo's YSlow and Google's Page Speed to analyze front-end problems, using Valgrind's Callgrind to analyze the Low-layer backend performance, and using XDebug to analyze the PHP performance of user space. In addition, he also pointed out the performance problems of the front-end of the read/write network.

Of course, the article also said that other aspects of Facebook's website may have been well optimized, so HipHop can bring enough efficiency.

In short, there is no universal silver bullet that is accurate to all corners of the world. In engineering, it is most important to select the most suitable tool for the current environment for detailed analysis of specific problems.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.