118 
 119 
 120 
 121 
 122 
 123 
 124 
 125 
 126 
 127 
 128 
 129 
 130 
 131 
 132 
 133 
 134 
 135 
 136 
 137 
 138 
 139 
 140 
 141 
 142 
 143 
 $cnt 10000;
 
 $GLOBALS['timer']->setMarker('__begin__');
 
 $string '';
 for ($i=0$i $cnt$i++)
 {
     $string .= 'texttexttexttexttexttexttexttexttexttexttexttext';
 }
 
 $GLOBALS['timer']->setMarker('string');
 
 $array = array();
 for ($i=0$i $cnt$i++)
 {
     $array[] = 'texttexttexttexttexttexttexttexttexttexttexttext';
 }
 
 $GLOBALS['timer']->setMarker('array');
 
 join(''$array);
 
 $GLOBALS['timer']->setMarker('join');
 
 require(DEV_DIR .'dbg_header.php');
 echo showSource(__FILE__1203, (__LINE__ 121), false);


  time idx ex time % mem mem +-
Start 0.000034 0.000000 0.00% 497,66 KB +497,66 KB
__begin__ 0.011458 0.011424 26.60% 1,44 MB +979,07 KB
string 0.016834 0.005376 12.52% 1,9 MB +468,84 KB
array 0.028558 0.011724 27.30% 3,47 MB +1,57 MB
join 0.039753 0.011195 26.06% 3,48 MB +17,72 KB
Stop 0.042985 0.003232 7.52% 3,49 MB +7,62 KB
total - 0.042951 100.00% 3,49 MB -