RE: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_vm_def.h zend_vm_execute.h

From: Date: Tue, 18 Jul 2006 16:36:19 +0000
Subject: RE: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_vm_def.h zend_vm_execute.h
References: 1  Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-5082@lists.php.net to get a copy of this message
Does this fix a warning or a bug? Because it might be intentional for performance reasons. You don't always want to initialize to shut up the compiler in places wwhich you want to get max performance out of. Andi > -----Original Message----- > From: Antony Dovgal [mailto:tony2001@php.net] > Sent: Wednesday, July 12, 2006 2:07 PM > To: zend-engine-cvs@lists.php.net > Subject: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_vm_def.h > zend_vm_execute.h > > tony2001 Wed Jul 12 21:07:07 2006 UTC > > Modified files: > /ZendEngine2 zend_vm_def.h zend_vm_execute.h > Log: > make sure return_value_used is always initialized > > > http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_vm_def.h?r1=1.1 > 23&r2=1.124&diff_format=u > Index: ZendEngine2/zend_vm_def.h > diff -u ZendEngine2/zend_vm_def.h:1.123 > ZendEngine2/zend_vm_def.h:1.124 > --- ZendEngine2/zend_vm_def.h:1.123 Wed Jul 12 17:04:13 2006 > +++ ZendEngine2/zend_vm_def.h Wed Jul 12 21:07:07 2006 > @@ -18,7 +18,7 @@ > > +------------------------------------------------------------- > ---------+ > */ > > -/* $Id: zend_vm_def.h,v 1.123 2006/07/12 17:04:13 andrei Exp $ */ > +/* $Id: zend_vm_def.h,v 1.124 2006/07/12 21:07:07 tony2001 Exp $ */ > > /* If you change this file, please regenerate the > zend_vm_execute.h and > * zend_vm_opcodes.h files by running: > @@ -2748,7 +2748,7 @@ > zend_op *opline = EX(opline); > zend_op_array *new_op_array=NULL; > zval **original_return_value = EG(return_value_ptr_ptr); > - int return_value_used; > + int return_value_used = RETURN_VALUE_USED(opline); > zend_free_op free_op1; > zval *inc_filename = GET_OP1_ZVAL_PTR(BP_VAR_R); > zval tmp_inc_filename; > @@ -2780,8 +2780,6 @@ > inc_filename = &tmp_inc_filename; > } > > - return_value_used = RETURN_VALUE_USED(opline); > - > switch (Z_LVAL(opline->op2.u.constant)) { > case ZEND_INCLUDE_ONCE: > case ZEND_REQUIRE_ONCE: { > http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_vm_execute.h?r1 > =1.127&r2=1.128&diff_format=u > Index: ZendEngine2/zend_vm_execute.h > diff -u ZendEngine2/zend_vm_execute.h:1.127 > ZendEngine2/zend_vm_execute.h:1.128 > --- ZendEngine2/zend_vm_execute.h:1.127 Wed Jul 12 17:04:13 2006 > +++ ZendEngine2/zend_vm_execute.h Wed Jul 12 21:07:07 2006 > @@ -1857,7 +1857,7 @@ > zend_op *opline = EX(opline); > zend_op_array *new_op_array=NULL; > zval **original_return_value = EG(return_value_ptr_ptr); > - int return_value_used; > + int return_value_used = RETURN_VALUE_USED(opline); > > zval *inc_filename = &opline->op1.u.constant; > zval tmp_inc_filename; > @@ -1889,8 +1889,6 @@ > inc_filename = &tmp_inc_filename; > } > > - return_value_used = RETURN_VALUE_USED(opline); > - > switch (Z_LVAL(opline->op2.u.constant)) { > case ZEND_INCLUDE_ONCE: > case ZEND_REQUIRE_ONCE: { > @@ -4437,7 +4435,7 @@ > zend_op *opline = EX(opline); > zend_op_array *new_op_array=NULL; > zval **original_return_value = EG(return_value_ptr_ptr); > - int return_value_used; > + int return_value_used = RETURN_VALUE_USED(opline); > zend_free_op free_op1; > zval *inc_filename = _get_zval_ptr_tmp(&opline->op1, > EX(Ts), &free_op1 TSRMLS_CC); > zval tmp_inc_filename; > @@ -4469,8 +4467,6 @@ > inc_filename = &tmp_inc_filename; > } > > - return_value_used = RETURN_VALUE_USED(opline); > - > switch (Z_LVAL(opline->op2.u.constant)) { > case ZEND_INCLUDE_ONCE: > case ZEND_REQUIRE_ONCE: { > @@ -7614,7 +7610,7 @@ > zend_op *opline = EX(opline); > zend_op_array *new_op_array=NULL; > zval **original_return_value = EG(return_value_ptr_ptr); > - int return_value_used; > + int return_value_used = RETURN_VALUE_USED(opline); > zend_free_op free_op1; > zval *inc_filename = _get_zval_ptr_var(&opline->op1, > EX(Ts), &free_op1 TSRMLS_CC); > zval tmp_inc_filename; > @@ -7646,8 +7642,6 @@ > inc_filename = &tmp_inc_filename; > } > > - return_value_used = RETURN_VALUE_USED(opline); > - > switch (Z_LVAL(opline->op2.u.constant)) { > case ZEND_INCLUDE_ONCE: > case ZEND_REQUIRE_ONCE: { > @@ -20387,7 +20381,7 @@ > zend_op *opline = EX(opline); > zend_op_array *new_op_array=NULL; > zval **original_return_value = EG(return_value_ptr_ptr); > - int return_value_used; > + int return_value_used = RETURN_VALUE_USED(opline); > > zval *inc_filename = _get_zval_ptr_cv(&opline->op1, > EX(Ts), BP_VAR_R TSRMLS_CC); > zval tmp_inc_filename; > @@ -20419,8 +20413,6 @@ > inc_filename = &tmp_inc_filename; > } > > - return_value_used = RETURN_VALUE_USED(opline); > - > switch (Z_LVAL(opline->op2.u.constant)) { > case ZEND_INCLUDE_ONCE: > case ZEND_REQUIRE_ONCE: { > > -- > Zend Engine CVS Mailing List (http://cvs.php.net/) To > unsubscribe, visit: http://www.php.net/unsub.php >

« previous php.zend-engine.cvs (#5082) next »