com php-src: Add -e (ZEND_EXT_* generation) option to phpdbg: sapi/phpdbg/phpdbg.c sapi/phpdbg/phpdbg _help.c
| From: | Bob Weinand | Date: | Wed, 22 Jul 2015 11:46:06 +0000 |
| Subject: | com php-src: Add -e (ZEND_EXT_* generation) option to phpdbg: sapi/phpdbg/phpdbg.c sapi/phpdbg/phpdbg _help.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-88113@lists.php.net to get a copy of this message | ||
Commit: 0da4a3ec2c3bfe0bfddbd17e0c757f71ae8d661b
Author: Bob Weinand <bobwei9@hotmail.com> Wed, 22 Jul 2015 13:46:06 +0200
Parents: cff6cbc01f64029abe76421d332e91ed655b5b43
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=0da4a3ec2c3bfe0bfddbd17e0c757f71ae8d661b
Log:
Add -e (ZEND_EXT_* generation) option to phpdbg
Changed paths:
M sapi/phpdbg/phpdbg.c
M sapi/phpdbg/phpdbg_help.c
Diff:
diff --git a/sapi/phpdbg/phpdbg.c b/sapi/phpdbg/phpdbg.c
index d594601..83425fe 100644
--- a/sapi/phpdbg/phpdbg.c
+++ b/sapi/phpdbg/phpdbg.c
@@ -966,6 +966,7 @@ const opt_struct OPTIONS[] = { /* {{{ */
{'I', 0, "ignore init"},
{'O', 1, "opline log"},
{'r', 0, "run"},
+ {'e', 0, "generate ext_stmt opcodes"},
{'E', 0, "step-through-eval"},
{'S', 1, "sapi-name"},
#ifndef _WIN32
@@ -1242,6 +1243,7 @@ int main(int argc, char **argv) /* {{{ */
int socket = -1;
FILE* stream = NULL;
char *print_opline_func;
+ zend_bool ext_stmt = 0;
#ifdef ZTS
void ***tsrm_ls;
@@ -1382,6 +1384,10 @@ phpdbg_main:
flags &= ~PHPDBG_IS_QUIET;
break;
+ case 'e':
+ ext_stmt = 1;
+ break;
+
case 'E': /* stepping through eval on */
flags |= PHPDBG_IS_STEPONEVAL;
break;
@@ -1693,6 +1699,10 @@ phpdbg_main:
cleaning = -1;
+ if (ext_stmt) {
+ CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO;
+ }
+
/* initialize from file */
PHPDBG_G(flags) |= PHPDBG_IS_INITIALIZING;
zend_try {
diff --git a/sapi/phpdbg/phpdbg_help.c b/sapi/phpdbg/phpdbg_help.c
index c2744b9..ea3df17 100644
--- a/sapi/phpdbg/phpdbg_help.c
+++ b/sapi/phpdbg/phpdbg_help.c
@@ -384,6 +384,7 @@ phpdbg_help_text_t phpdbg_help_text[] = {
" **-O** **-O**my.oplog Sets oplog output file" CR
" **-r** Run execution context" CR
" **-rr** Run execution context and quit after execution" CR
+" **-e** Generate extended information for debugger/profiler"
CR
" **-E** Enable step through eval, careful!" CR
" **-S** **-S**cli Override SAPI name, careful!" CR
" **-l** **-l**4000 Setup remote console ports" CR