Execution time evaluation

hi,

I use XAMPP  to run PHP.  I want to know the functions available for evaluate  execution time and little explanation for how can use that and occations that we can use that functions.  
LVL 3
shaf81Asked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
ycTINConnect With a Mentor Commented:

<?php
$time_start = microtime(true);//record start time
 
//repeat 10000 time
$i = 10000;
while ($i--) {
	//process
}
 
$time_end = microtime(true);//record end time
 
//calculate and format output
$time = number_format(($time_end - $time_start) * 1000,4);
echo "execution time : $time ms\n";
?>

Open in new window

0
 
max-hbConnect With a Mentor Commented:
Hi!
If you need a more sophisticated profiling tool take a look at http://freshmeat.net/projects/phpprofiler/

phpprofiler offers you several options to fine tune profiling and enables you to measure performance of nested blocks.

CU
 maxhb
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.