Total time taken to generate the page [message #19214] |
Fri, 02 July 2004 08:46 |
djnz
Messages: 14 Registered: July 2004
Karma: 0
|
Junior Member |
|
|
There are always problems with template engines and time displays, but with FUDforum this seems to be quite extreme. If you put a timer outside FUDforum the overall execution time on my server seems to be consistently 0.007s greater than displayed by FUDforum. Now this is not a lot in absolute terms, but with typical times displayed by FUDforum less than 0.01s it is relatively high.
|
|
|
|
|
Re: Total time taken to generate the page [message #19228 is a reply to message #19225] |
Fri, 02 July 2004 13:46 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
You are still timing how long it takes to stick the page into a buffer. You are also timing how long it takes to parse & load index.php into memory as well as all of the files it includes.
FUDforum Core Developer
|
|
|
|
Re: Total time taken to generate the page [message #19232 is a reply to message #19231] |
Fri, 02 July 2004 14:12 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
The time taken to generate the page is how long it took for the forum code to generate the given output. The time taken to buffer or send the output to the user does not count nor does the time taken for PHP to parse the scripts. The latter becomes irrelevant anyway with a opcode caching system. The former may be included inside in the timings anyway if you use the forum's .htaccess files that will force buffering of most pages in memory before being sent to the user.
0.007 is a very small number indeed just looking at your code you have 2 defines (slow), 2 timing calls and 1 realpath (very slow) and then of course parsing of index.php itself. This can easily cover 0.00[3-4].
FUDforum Core Developer
|
|
|
|
|
Re: Total time taken to generate the page [message #19471 is a reply to message #19468] |
Thu, 22 July 2004 18:29 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
The parsing of PHP files is a tricky as far as time goes. The primary thing is that this depends on your drive speed unless you use an opcode cache. If and when opcode cache is used parsing a file becomes a very very fast process. Testing the speed of the script from within itself is a very unprecise process unless you isolate a bit of code, put it into a very long loop and time it. This will ensure that random effects and parsing times are averaged out.
FUDforum Core Developer
|
|
|