minute performance gain

From: Date: Sun, 17 Oct 2004 18:05:15 +0000
Subject: minute performance gain
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-33908@lists.php.net to get a copy of this message
Hi, I took the register_shutdown_function and moved it to the PEAR class constructor, inside the code that checks for destructors, and found a miniscule performance gain. Zend IDE's profiler reported that the time it takes to run 'PEAR.php'; decreased from .35 ms to .28 ms. By far the most significant performance hit comes from the require_once call, which leads me to believe that even using PEAR_Exception would do nothing to improve performance unless you put everything in 1 big-ass file. :) For comparison, I took the file <?php ?> and profiled it, getting .02 ms, so the time it takes to parse PEAR.php is about .26 ms - not exactly big potatoes. Greg

« previous php.pear.dev (#33908) next »