Created
May 2, 2011 16:00
-
-
Save branneman/951833 to your computer and use it in GitHub Desktop.
Timing script execution at high-precision
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$time1 = explode(' ', microtime()); | |
$time1 = $time1[1] . substr($time1[0], 1, -2); | |
// your code | |
$time2 = explode(' ', microtime()); | |
$time2 = $time2[1] . substr($time2[0], 1, -2); | |
var_dump(bcsub($time2, $time1, 6)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment