View Issue Details

IDProjectCategoryView StatusLast Update
0001216XdebugUncategorizedpublic2021-03-17 09:22
Reporterderick Assigned To 
PrioritynormalSeverityminorReproducibilityhave not tried
Status resolvedResolutionno change required 
Summary0001216: Investigate optimisations in when to turn things on and off
Description

Try to not have too much overhead for when specific features are not enabled or so.

TagsNo tags attached.
Operating System
PHP Version5.6.15-5.6.19

Activities

derick

2015-11-29 21:01

administrator   ~0003272

diff --git a/xdebug.c b/xdebug.c
index ae63993..ea2b304 100644
--- a/xdebug.c
+++ b/xdebug.c
@@ -1629,10 +1629,14 @@ void xdebug_execute(zend_op_array *op_array TSRMLS_DC)

#if PHP_VERSION_ID >= 70000
/* For PHP 7, we need to reset the opline to the start, so that all opcode

    • handlers are being hit. But not for generators, as that would make an
    • endless loop. TODO: Fix RECV handling with generators. */
  • if (!(EX(func)->op_array.fn_flags & ZEND_ACC_GENERATOR)) {
  • EX(opline) = EX(func)->op_array.opcodes;
    • handlers are being hit. This is only important when we are doing code
    • coverage, so only do it when path/branch coverage is requested. But not
    • for generators, as that would make an endless loop. TODO: Fix RECV
    • handling with generators. */
  • if (XG(do_code_coverage) && XG(code_coverage_branch_check)) {
  • if (!(EX(func)->op_array.fn_flags & ZEND_ACC_GENERATOR)) {
  • EX(opline) = EX(func)->op_array.opcodes;
  • }
    }
    #endif

derick

2016-12-13 21:42

administrator   ~0004056

I might want to implement this, but it's not high on my list of things to do.

derick

2021-03-17 09:22

administrator   ~0005741

This is what Xdebug 3 did.