HipHop für PHP

Der Schleier wurde gelüftet: Facebook hat mit »HipHop« einen Source Code Umwandler veröffentlicht, der PHP-Code in höchst-optimierten C++ Code konvertiert. Dieser wiederum wird dann mit g++ kompiliert um maximale Performance zu erreichen.

Bei Facebook brachte der Einsatz von HipHop eine durchschnittliche Reduzierung der CPU-Auslastung um 50% – natürlich abhängig von der jeweiligen Seite. Für Facebook bedeutet weniger CPU-Last weniger Server – und damit weniger Kosten. Aber natürlich bedeutet weniger Auslastung auch weniger Energieverbrauch.

In seinem Blog-Beitrag schreibt Haiping Zhao »We are proud to say that at this point, we are serving over 90% of our Web traffic using HipHop, all only six months after deployment.

How HipHop Works
The main challenge of the project was bridging the gap between PHP and C++. PHP is a scripting language with dynamic, weak typing. C++ is a compiled language with static typing. While PHP allows you to write magical dynamic features, most PHP is relatively straightforward. It’s more likely that you see if (…) {…} else {..} than it is to see function foo($x) { include $x; }. This is where we gain in performance. Whenever possible our generated code uses static binding for functions and variables. We also use type inference to pick the most specific type possible for our variables and thus save memory.

[…]

Overall HipHop allows us to keep the best aspects of PHP while taking advantage of the performance benefits of C++. In total, we have written over 300,000 lines of code and more than 5,000 unit tests. All of this will be released this evening on GitHub under the open source PHP license.

Der ganze Artikel (englisch) im Facebook Blog: http://developers.facebook.com/news.php?blog=1&story=358

Optimizing TYPO3 backend responsiveness

During the last months I attended two excellent meetings. One was the TYPO3DD08 and the other was the „Dirty Handson Session“ (Forelle ist geil!). During the last session we worked on HCI issues in Arnhem @ the Netcreators office together with Ben van ‚t Ende, Benjamin Mack, Jens Hoffmann, Patrick Broens, Steffen Kamper and me. We had a lot of fun and made a good start improving the backend step by step….

http://typofree.org/articles/optimizing-typo3-backend-responsiveness/

PHP 5.3 bis zu 30 Prozent schneller

PHP 5.3 bis zu 30 Prozent schneller: „Die Entwickler der freien Scriptsprache PHP haben begonnen, PHP von einem veralteten, Flex-basierten Lexer auf re2c umzustellen. Die aktuelle Entwicklerversion von PHP 5.3 wird dadurch um bis zu 30 Prozent schneller. (PHP, WordPress)“

Erst Benchmarks der aktuellen Entwicklerversion von PHP 5.3 mit PHP 5.2, die Dmitry Stogov veröffentlichte, sehen vielversprechend aus: Demnach ist PHP 5.3 bis zu 30 Prozent schneller als sein Vorgänger. Gemessen wurden die PHP-Applikationen Drupal (20 Prozent schneller), Qdig (2 Prozent schneller), Typo3 (30 Prozent schneller), WordPress (15 Prozent schneller) und Xoops (10 Prozent schneller).

(Via Golem.de.)

Yahoo: Wie man Webseiten schneller macht

Yahoo: Wie man Webseiten schneller macht: „Yahoos Exceptional-Performance-Team beschäftigt sich mit der Frage, wie man Webseiten schneller macht, von Maßnahmen auf Serverseite über die Inhalte bis hin zu Cookies, JavaScript, CSS-Bildern und den speziellen Anforderungen mobiler Webseiten. Nach den ersten 14 Regeln für schnellere Webseiten hat Yahoo nun 20 weitere Tipps veröffentlicht. (AJAX, iPhone)“

(Via Golem.de.)