Re: [SMARTY] yet another benchmark
| From: | Monte Ohrt | Date: | Fri, 14 Jun 2002 14:30:54 +0000 |
| Subject: | Re: [SMARTY] yet another benchmark | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-4839@lists.php.net to get a copy of this message | ||
Well that's not really the point. First of all, you are correct in saying that 2.7 seconds vs 3 seconds doesn't make much difference when you look at one page load. But, when you look at 1 million page loads, it _does_ make a difference in system load and performance over time.
But in this case, one engine takes 2.7 seconds to print a template, one takes 3 seconds to parse/print, and one takes 3.1 to parse/print then show a cached copy. These numbers don't mean squat, you aren't even comparing the same operations. The best thing to do is setup a complete benchmark, run it X times and compare the total time. That is what the current benchmarks do.
Sean Chambers wrote:
Not to go off topic but I feel I can contirbute to the conversation: For the past 2 years that I've been using PHP I notice a very very slight difference in general on 56k, cable modem, dsl and T1 parsing of PHP files I understand that some people say classes are slower which I believe they are, but not to the point that you could even tell a difference. With a difference of 3,2.7 and 3.1 seconds, you probably couldn't even blink your eye in the time that your saving. -----Original Message----- From: Monte Ohrt [mailto:monte@ispi.net] Sent: Friday, June 14, 2002 10:01 AM To: Ivo Jansch Cc: smarty-general@lists.php.net Subject: Re: [SMARTY] yet another benchmark I still don't see how the benchmark results would be anything conclusive. For instance, Smarty parses/prints in one function. If I run display() 50 times in Smarty, it will parse/compile the first time and execute the compiled template 50 times. Fine. So in FastTemplate, I execute FastPrint() 50 times, which just echoes the template (parsing done). In ModeliXe, the page is cached so all subsequent calls come from the cache. So maybe Smarty takes 3 seconds, FastTemplate takes 2.7 seconds and Modelixe takes 3.1 seconds. What does this mean? One is faster at printing than the other is a parsing/printing? One engine is better than the other because of these numbers? I think the results would be non-conclusive, or even misleading. Ivo Jansch wrote:-- Monte Ohrt <monte@ispi.net> Director of Technology, ispi Inc.Hi, Monte Ohrt wrote:fetch.Well this is a tough benchmark to make fair. Some template engines combine the parse/print functionality, some do not. So a fetch of a template 50 times might be parsing and printing, or just printing. ModeliXe uses a cached copy so subsequent fetches are just a fileWhat is 'fair' in this case anyway? Benchmarks are there for users to find out which solution is the best for their needs. The purpose ofanytemplate engine is 'to turn a template into an html file'. How the engine does that is irrelevant. That Smarty parses the template only once, making it ultrafast, does not make it an 'unfair' templateengine.Benchmarking template engines without measuring their 'core business' would be like trying to benchmark formula 1 cars by just measuring howfast you can put fuel in it. :) Greetings, Ivo