Screen2.0

 
 
 

news, hints & tips, links // 2010.07.29 08:09:16 [hh]

Aus Scripten binäre Programme machen: "HipHop for PHP"

Ein Entwickler-Team von "Facebook" um Haiping Zhao hat einen interessanten Ansatz zur Optimierung von PHP-Code gefunden. Mittels Code-Transformationen soll aus PHP-Code C++ Code entstehen, der dann compiliert werden kann. Laut Entwickler des 300.000 Zeilen umfassenden Open-Source-Projektes "HipHop for PHP" soll damit die CPU-Last um 50 Prozent reduziert werden können. "Facebook" liefert bereits 90% aller Seiten in "HipHop"-optimierter Form aus.

Haiping Zhao zu dem Tool: "HipHop for PHP isn't technically a compiler itself. Rather it is a source code transformer. HipHop programmatically transforms your 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."



Weitere Informationen: github.com/ facebook/ hiphop-php

 

Werbung