Re: Vote: PEAR::Strip_Comments

From: Date: Wed, 28 Apr 2004 20:58:36 +0000
Subject: Re: Vote: PEAR::Strip_Comments
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-12197@lists.php.net to get a copy of this message
> My suspicion is that the difference in access and/or overhead > performance of code with comments and code without is negligible, > particularly if you're using a PHP accelerator like Turck MMCache. Right, if you choose an accelerator the cached files do not contain any comments anymore, that's what I have heard. > If you decide to run benchmarks, please post the tests you ran and their > results. Using the PEAR::Benchmark and the following code <?php require 'Benchmark/Timer.php'; $timer = new Benchmark_Timer(); $timer->start(); //require_once("HUGE_FILE.php"); require_once("SMALL_FILE.php"); $timer->stop(); $timer->display(); ?> where HUGE_FILE.php (48288) is my Image_Imagick.php proposal (http://www.siteartwork.de/image_imagick/Imagick.tgz) with comments and the SMALL_FILE.php (18475) (manually) stripped down (leaving white-spaces and new lines), I got the following results: HUGE_FILE.php ============ Lowest: 0.013940 Peak: 0.024210 SMALL_FILE.php ============ Lowest: 0.010831 Peak: 0.015010 (WindowsXP, Apache 1.3, PHP4.3, 512 MB RAM, 1.7 Celeron)

« previous php.pear.general (#12197) next »