Performance: Scaling PHP
Profile your code
foreach ($_SERVER as $k => $v)
  if (substr($k, 0, 5) == “HTTP_”)
     $str .= substr($k, 5) . “: $v\n”;
versus:
  if (strncmp($k, “HTTP_”, 5) == 0)
Implement C and C++ extensions
when you’re willing to trade flexibility for speed
Use an Accelerator