David Brown | 1 Jun 2003 01:36

[PHP-DEV] Bug #22510: Working toward a fix...

Hi:

I believe there's a missing refcount increment causing this bug, and I
think I may have uncovered some evidence that could get us closer to a
fix. I've added opcode dumps to zend_execute.c with a well-placed perl
command, so as to see the instructions as they're executed.

All of the following has been performed against a clean snapshot of PHP4
CVS HEAD.

Given the following script, containing one class with two methods
differing only by a silence operator:

  <?php
    class foo
    {
      function &method1() {
        return $this->foo;
      }

      function &method2() {
        return  <at> $this->foo;
      }
    }

    $i = new foo();
    $i->method1();
    echo "\n";
    $i->method2();
  ?>
(Continue reading)

David Brown | 1 Jun 2003 02:04

[PHP-DEV] Re: CVS commit in ZendEngine2/zend_execute.c

> zend_execute.c, 1.468 (sterling)
> Sat May 31 14:31:28 2003 (5 hours, 35 minutes ago)
> revert the function call caching patch until a new solution is decided
> upon.

Hi:

Is this being reverted due to a reported crash? If not, I'm currently
seeing several with the patch applied (which go away with the recent
revert). Valgrind says:

 Conditional jump or move depends on uninitialised value(s)
   at 0x817367D: zend_init_fcall_by_name_handler (zend_execute.c:2565)
    by 0x816EC54: execute (zend_execute.c:1247)
    by 0x8173B14: zend_do_fcall_common_helper (zend_execute.c:2654)
    by 0x8173F6A: zend_do_fcall_by_name_handler (zend_execute.c:2725)

I can supply backtraces and try to derive a test case if this is a new
crash.  If not, I'm relieved that I wasn't debugging alone - I've had a
'0 &&' in the reverted if() for the past 12 hours. :)

Thanks a lot,

- Dave
  dave <at> codewhore.org

--

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

(Continue reading)

Marcus Börger | 1 Jun 2003 02:34
Picon
Favicon

Re: [PHP-DEV] Re: CVS commit in ZendEngine2/zend_execute.c

At 02:04 01.06.2003, David Brown wrote:
> > zend_execute.c, 1.468 (sterling)
> > Sat May 31 14:31:28 2003 (5 hours, 35 minutes ago)
> > revert the function call caching patch until a new solution is decided
> > upon.
>
>Hi:
>
>Is this being reverted due to a reported crash? If not, I'm currently
>seeing several with the patch applied (which go away with the recent
>revert). Valgrind says:
>
>  Conditional jump or move depends on uninitialised value(s)
>    at 0x817367D: zend_init_fcall_by_name_handler (zend_execute.c:2565)
>     by 0x816EC54: execute (zend_execute.c:1247)
>     by 0x8173B14: zend_do_fcall_common_helper (zend_execute.c:2654)
>     by 0x8173F6A: zend_do_fcall_by_name_handler (zend_execute.c:2725)
>
>I can supply backtraces and try to derive a test case if this is a new
>crash.  If not, I'm relieved that I wasn't debugging alone - I've had a
>'0 &&' in the reverted if() for the past 12 hours. :)

Yes David,

in ZTS mode it causes much problems, i found them some hours ago. But the main
reason for revert is that the patch was done in the wrong way. Currently we 
are trying
to figure out a new way since the performance boost is very good.

regards
(Continue reading)

David Brown | 1 Jun 2003 02:40

Re: [PHP-DEV] Re: CVS commit in ZendEngine2/zend_execute.c

On Sun, Jun 01, 2003 at 02:34:41AM +0200, Marcus B?rger wrote:
| Yes David,
| 
| in ZTS mode it causes much problems, i found them some hours ago. But
| the main reason for revert is that the patch was done in the wrong
| way. Currently we are trying to figure out a new way since the
| performance boost is very good.

Hi Marcus,

The crash I was seeing was under the CLI sapi, without ZTS enabled.
If this is unexpected, I can try for a test case. Otherwise, if you're
pretty sure the patch had more wrong with it than there was right, I'll
hold off. :)

The codebase I was seeing the crash in is large and reasonably complex -
I was just checking to make sure that the patch was indeed causing the
problem, not just making it visible.

Anyway. Much thanks. :)

- Dave

--

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Jon Parise | 1 Jun 2003 09:12
Picon

[PHP-DEV] bindlib_w32 fix for Visual Studio .NET (resend)

I sent the attached message to php-dev a few months ago.  I failed to
receive a response, but I've been compiling with the attached patch
for months now, and I'm confident in the fix.

If no one objects, I'd like to see this committed to CVS.  Or, even
better, I'd like to receive karma for the bindlib_w32 module and
commit the patch myself.

-- 
Jon Parise (jon <at> php.net) :: The PHP Project (http://www.php.net/)

--

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Jon Parise | 1 Jun 2003 09:21
Picon

[PHP-DEV] bindlib_w32 fix for Visual Studio .NET (resend)

My previous message was missing the attachments.

-- 
Jon Parise (jon <at> php.net) :: The PHP Project (http://www.php.net/)
I ran into a problem when building bindlib_w32 using Visual Studio
.NEt under Windows XP:

nsap_addr.c(38) : error C2491: 'isxdigit' : definition of dllimport function not allowed

The attached patch corrects this problem.  I don't have commit
privileges for the bindlib_w32 module, so if someone could either
grant me karma or commit this for me, I'd appreciate it.

--

-- 
Jon Parise (jon <at> php.net) :: The PHP Project (http://www.php.net/)
Index: nsap_addr.c
===================================================================
RCS file: /repository/bindlib_w32/nsap_addr.c,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 nsap_addr.c
--- nsap_addr.c	26 Apr 1999 14:02:36 -0000	1.1.1.1
+++ nsap_addr.c	22 Feb 2003 20:54:56 -0000
 <at>  <at>  -31,7 +31,8  <at>  <at> 

 #include "conf/portability.h"

(Continue reading)

Zeev Suraski | 1 Jun 2003 16:32
Favicon
Gravatar

[PHP-DEV] Re: bindlib_w32 fix for Visual Studio .NET (resend)

Applied.

At 10:12 01/06/2003, Jon Parise wrote:
>I sent the attached message to php-dev a few months ago.  I failed to
>receive a response, but I've been compiling with the attached patch
>for months now, and I'm confident in the fix.
>
>If no one objects, I'd like to see this committed to CVS.  Or, even
>better, I'd like to receive karma for the bindlib_w32 module and
>commit the patch myself.
>
>--
>Jon Parise (jon <at> php.net) :: The PHP Project (http://www.php.net/)
>I ran into a problem when building bindlib_w32 using Visual Studio
>.NEt under Windows XP:
>
>nsap_addr.c(38) : error C2491: 'isxdigit' : definition of dllimport 
>function not allowed
>
>The attached patch corrects this problem.  I don't have commit
>privileges for the bindlib_w32 module, so if someone could either
>grant me karma or commit this for me, I'd appreciate it.
>
>--
>Jon Parise (jon <at> php.net) :: The PHP Project (http://www.php.net/)

--

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

(Continue reading)

Derick Rethans | 1 Jun 2003 19:16
Picon
Favicon

[PHP-DEV] Re: #23873 [Fbk->Bgs]: Error in sapi_apache2.lo

On Sun, 1 Jun 2003 sniper <at> php.net wrote:

>  ID:               23873
>  Reported By:      matthijs at vanbokhorst dot net
>  Operating System: RedHat 7.3/kernel 2.4.20
>  PHP Version:      4.3.2
>  New Comment:
> 
> >From ./configure --help output:
> 
> "  --with-regex=TYPE       regex library type: system, apache, php.
> Default: php
>                           WARNING: Do NOT use unless you know what you
> are doing!"
> 
> This is no bug, don't use configure options which
> you don't know why/when to use.

What about removing this option? AFAIK you never need to set it...

Derick

--

-- 

-------------------------------------------------------------------------
 Derick Rethans                                 http://derickrethans.nl/ 
 JDI Media Solutions                             http://www.jdimedia.nl/
 International PHP Magazine                      http://www.php-mag.net/
-------------------------------------------------------------------------

(Continue reading)

Cristiano Duarte | 1 Jun 2003 22:29
Picon
Favicon

[PHP-DEV] Re: final classes and const references to objects

Hello...
Is anyone thinking about it ?

"Cristiano Duarte" <cunha17 <at> uol.com.br> escreveu na mensagem
news:20030509171832.30305.qmail <at> pb1.pair.com...
> What a work in Zend2 !!! It is getting great, but about object constants
in
> class definition?
> I need to do something like this:
>
> class EnumException extends Exception{ }
> final class Car {
>     //private
>     const _ferrari = 0;
>     const _porsche = 1;
>     const _corvette = 2;
>
>     //private
>     const _last_value = 2;
>
>     //public
>     const ferrari = new Car(_ferrari);
>     const porsche = new Car(_porsche);
>     const corvette = new Car(_corvette);
>
>     private $value;
>
>     protected function __construct($value) {
>         if (($value < 0) || ($value > _last_value)) {
>             throw new EnumException();
(Continue reading)

Stig S. Bakken | 2 Jun 2003 09:49

Re: [PHP-DEV] Re: #23873 [Fbk->Bgs]: Error in sapi_apache2.lo

On Sun, 2003-06-01 at 19:16, Derick Rethans wrote:
> On Sun, 1 Jun 2003 sniper <at> php.net wrote:
> 
> >  ID:               23873
> >  Reported By:      matthijs at vanbokhorst dot net
> >  Operating System: RedHat 7.3/kernel 2.4.20
> >  PHP Version:      4.3.2
> >  New Comment:
> > 
> > >From ./configure --help output:
> > 
> > "  --with-regex=TYPE       regex library type: system, apache, php.
> > Default: php
> >                           WARNING: Do NOT use unless you know what you
> > are doing!"
> > 
> > This is no bug, don't use configure options which
> > you don't know why/when to use.
> 
> What about removing this option? AFAIK you never need to set it...

It's there in case for example Apache is built with the system regex
library.  On systems like Solaris, bad things happen if you mix the
system and hs regex libs.

 - Stig

--

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
(Continue reading)


Gmane