Getting the Time of Styling - GeSHi/geshi-1.0 GitHub Wiki

Once you’ve called parse_code(), you can get the time it took to run the highlighting by calling the get_time() method:

$geshi = new GeSHi($source, $language, $path);
 
$code = mysql_real_escape_string($geshi->parse_code());
$time = $geshi->get_time();
 
// do something with it
mysql_query("INSERT INTO code VALUES ('$code', '$time')");