RE: [PHP-DEV] Doing something with an each opcode as zend_execute() handles it

From: Date: Wed, 05 Mar 2003 23:00:28 +0000
Subject: RE: [PHP-DEV] Doing something with an each opcode as zend_execute() handles it
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-94819@lists.php.net to get a copy of this message
On Wednesday, March 05, 2003 5:35 PM, Sterling Hughes wrote: >> Just before zend_execute()/execute() handles each opcode in its big >> switch() statement, I'd like to be able to call a function and pass >> it the opcode (or other information from the opline. >> >> Is the best approach to reset zend_execute to a new function in the >> PHP_MINIT_FUNCTION() (and restore the saved value in >> PHP_MSHUTDOWN_FUNCTION)? This new function would mostly be a copy of >> execute() in zend_execute.c with my addtional function call tossed >> in. >> >> What's the difference between zend_execute() and >> zend_execute_internal()? >> > > Well, I have a feeling what you are talking about is sub-optimal, > what do you want to do? Essentially, I want to be able to produce a sort of serialized representation of the opcodes, but as they are executed, not all in one big chunk after they are compiled. This isn't for any actually useful production code, just some debugging/messing around/exploring engine internals. David

« previous php.dev (#94819) next »