- Output miliseconds instead of second, much easier to read without
a bunch of leading zeros
- Give precision up to the microsecond in benchmarkHooks
Change-Id: Id47e55eb311c926757c50a432c8992999908c03e
$end = microtime( true );
- echo "Delete: " . $end - $start;
+ echo "Delete: " . sprintf( "%6.3fms", ( $end - $start ) * 1000 );
echo "\r\n";
$this->insertData( $dbw );
$end = microtime( true );
- echo "Truncate: " . $end - $start;
+ echo "Truncate: " . sprintf( "%6.3fms", ( $end - $start ) * 1000 );
echo "\r\n";
$dbw->dropTable( 'test' );
}
$delta = microtime( true ) - $start;
$pertrial = $delta / $trials;
- return sprintf( "Took %6.2fs",
- $pertrial );
+ return sprintf( "Took %6.3fms",
+ $pertrial * 1000 );
}
/**