Re: Date function kill lots time !
| From: | Adam Richardson | Date: | Thu, 05 Jan 2012 06:29:25 +0000 |
| Subject: | Re: Date function kill lots time ! | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-316175@lists.php.net to get a copy of this message | ||
On Wed, Jan 4, 2012 at 11:07 PM, xucheng <helloworldjerry@gmail.com> wrote:
> hi all,
> I have a webapp which track visitors, and use xhprof for profiling my
> codes .
> After reading some reports produced by xhprof, i found that function
> Date() kills most time of my app !
> how can this happen ? Is this function has some internal issue that i
> should kown ?
> Any comment appreciate ! thanks !
>
> --
> RTFSC - Read The F**king Source Code :)!
>
Did you set the timezone? If not, PHP raises a notice, which causes
terrible performance (see the comment at the bottom):
https://bugs.php.net/bug.php?id=39968
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com