php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #15876 odd slowdown in calling small sections of php code
Submitted: 2002-03-05 09:27 UTC Modified: 2002-10-20 23:25 UTC
From: ddp at deakin dot edu dot au Assigned:
Status: No Feedback Package: Performance problem
PHP Version: 4.1.1 OS: linux 2.4.17 & solaris 8
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: ddp at deakin dot edu dot au
New email:
PHP Version: OS:

 

 [2002-03-05 09:27 UTC] ddp at deakin dot edu dot au
here's part of the code that causes the problem:

if(isset($timer)) $four=$timer->get();

    if( !empty( $ev->repeat_id) )
        printf( "&REPEAT_ID=%s", $ev->repeat_id);
    if(!empty($end_date)) print "&END_DATE=$end_date";

if(isset($timer)) $five=$timer->get();


Produces the following timings:
four=3.0422940254211, five=3.4876440763474

Interestingly, this is repeatable many times through several different pages, but in different sections of code (all seemingly innocuous and they definitely 'behave' correctly most of the time, e.g. 1 time out of 15 in a loop on the same page the above code will give that slow response, the other times it will execute quickly):
four=4.3863810300827, five=4.3864229917526

Other info (sorry, I don't think I can give you a small script).
Configure line:
 './configure' '--prefix=/opt/local/packages/php-4.1.1' '--with-jpeg-dir=/opt/local/' '--with-png-dir=/opt/local/' '--with-zlib-dir=/opt/local/' '--with-xpm-dir=/opt/local/' '--with-imap=/src/archive/i/imaped/imap-2001a' '--enable-inline-optimization' '--enable-bcmath' '--enable-calendar' '--with-regex=system' '--with-apache=/src/archive/a/apache/prod_build/apache_1.3.23' '--with-ftp' '--with-oracle' '--with-oci8=/opt/local/packages/oracle-9.0.1' '--with-snmp=/opt/local/' '--with-yp' '--enable-ucd-snmp-hack' '--with-openssl' '--with-config-file-path=/local/etc/httpd/' '--enable-safe-mode' '--enable-track-vars' '--enable-trans-sid' '--enable-magic-quotes' '--with-gd=/opt/local/' '--enable-gd-imgstrttf' '--enable-xml'

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-03-05 22:28 UTC] ddp at deakin dot edu dot au
Forgot to add the timer code is based on
// Deathhead's Timer
// http://phpclasses.upperdesign.com/browse.html/package/431/
 [2002-10-05 20:28 UTC] iliaa@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php4-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-latest.zip


 [2002-10-20 23:25 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over 2 weeks, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Sat Dec 03 05:05:53 2022 UTC