summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Schneider2012-08-24 13:28:55 +0000
committerChristian Schneider2012-08-24 13:28:55 +0000
commit4c00390d2a24fdaaf38969abdae8fdceede7c3df (patch)
tree6a9b59654dab3349b891ef466b2d0f979944a0d9
parent7abbf2ce713200bb62ed472884a7ddef84111416 (diff)
downloaditools-4c00390d2a24fdaaf38969abdae8fdceede7c3df.tar.gz
itools-4c00390d2a24fdaaf38969abdae8fdceede7c3df.tar.bz2
itools-4c00390d2a24fdaaf38969abdae8fdceede7c3df.zip
Also use float time in it::timerlog()
-rw-r--r--it.class7
1 files changed, 1 insertions, 6 deletions
diff --git a/it.class b/it.class
index 6a9bd4c..739653b 100644
--- a/it.class
+++ b/it.class
@@ -104,12 +104,7 @@ static function log($name /* ... */)
static function timerlog($label = '')
{
if ($GLOBALS['debug_timerlog'])
- {
- $s = $GLOBALS['ULTRATIME'];
- $e = gettimeofday();
- $msec= ($e['sec'] - $s['sec']) * 1000 + ($e['usec'] - $s['usec']) / 1000;
- $GLOBALS['ULTRATIMERLOG'] .= sprintf(" %s:%d", $label, $msec);
- }
+ $GLOBALS['ULTRATIMERLOG'] .= sprintf(" %s:%d", $label, (microtime(true) - $GLOBALS['ULTRATIME'])*1000);
}