Re: minute performance gain
| From: | Jon Parise | Date: | Mon, 18 Oct 2004 15:21:36 +0000 |
| Subject: | Re: minute performance gain | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-33937@lists.php.net to get a copy of this message | ||
On Sun, Oct 17, 2004 at 02:05:15PM -0400, Greg Beaver wrote:
> 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. :)
To be fair, you only see this performance gain when no destructor is
exists (and register_shutdown_function() is not called), yes?
--
Jon Parise (jon of php.net) :: The PHP Project (http://www.php.net/)