Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Execution time evaluation

Posted on 2009-05-18
2
Medium Priority
?
251 Views
Last Modified: 2012-05-07
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.  
0
Comment
Question by:shaf81
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 7

Accepted Solution

by:
ycTIN earned 1050 total points
ID: 24411948

<?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
 
LVL 4

Assisted Solution

by:max-hb
max-hb earned 450 total points
ID: 24412494
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

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I imagine that there are some, like me, who require a way of getting currency exchange rates for implementation in web project from time to time, so I thought I would share a solution that I have developed for this purpose. It turns out that Yaho…
3 proven steps to speed up Magento powered sites. The article focus is on optimizing time to first byte (TTFB), full page caching and configuring server for optimal performance.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question