Re: [ZEND-ENGINE-CVS] cvs: ZendEngine2(PHP_5_3) / zend.c zend_execute_API.c zend_vm_def.h zend_vm_execute.h php-src NEWS
| From: | Dmitry Stogov | Date: | Thu, 17 Apr 2008 06:58:10 +0000 |
| Subject: | Re: [ZEND-ENGINE-CVS] cvs: ZendEngine2(PHP_5_3) / zend.c zend_execute_API.c zend_vm_def.h zend_vm_execute.h php-src NEWS | ||
| References: | 1 2 3 4 | Groups: | php.internals php.zend-engine.cvs |
| Request: | Send a blank email to internals+get-37050@lists.php.net to get a copy of this message | ||
Another idea: In case xdebug overwrites zend_execute() it can set EG(return_value_ptr_ptr) to point to some local variable then call original executor and then print pass return_value to caller or destroy it dependent on previous value of EG(return_value_ptr_ptr).
Thanks. Dmitry.
Derick Rethans wrote:
On Fri, 11 Apr 2008, Dmitry Stogov wrote:Sorry, but I think mainly about PHP performance, and of course I didn't know that you trace return_values it in xdebug. After the patch, in case if return value is not used we set EG(return_value_ptr_ptr) to NULL before call to nested execute(). I assume you can just check for (EG(return_value_ptr_ptr)==NULL) before write it. Will it work for you?I'm already doing that, so not went really wrong. I am just wondering whether it would be possible to always have those return values there through some kind of option. regards, Derick