Re: optimization ?
| From: | Ignacio Vazquez-Abrams | Date: | Sun, 17 Dec 2000 21:18:08 +0000 |
| Subject: | Re: optimization ? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-30762@lists.php.net to get a copy of this message | ||
On Sun, 17 Dec 2000, Jon Rosenberg wrote:
> Can anyone recommend a resource on optimizing php code? I just installed
> the zend optimizer and am seeing about a 20% increase in speed, but I want
> to optimize my code as well. I'm looking for things like variable length
> hits, type conversion hits, how to reduce mem usage...etc. Thanks
>
> Jon
>
> and while I've got your attention, is one of these faster than the other b/c
> of variable name lenght or increase in total php file size?
>
> $bob_goes_to_market_on_tuesday = "pickles";
> $bob = "pickles";
>
If you REALLY want to scrimp on clock cycles then yes, the second is faster.
But not by more than maybe 2 microseconds on a slow machine.
--
Ignacio Vazquez-Abrams <ignacio@openservices.net>