Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:93063 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 85041 invoked from network); 4 May 2016 08:56:32 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 May 2016 08:56:32 -0000 Authentication-Results: pb1.pair.com header.from=pthreads@pthreads.org; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=pthreads@pthreads.org; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain pthreads.org from 209.85.161.193 cause and error) X-PHP-List-Original-Sender: pthreads@pthreads.org X-Host-Fingerprint: 209.85.161.193 mail-yw0-f193.google.com Received: from [209.85.161.193] ([209.85.161.193:36655] helo=mail-yw0-f193.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id D9/21-08540-B39B9275 for ; Wed, 04 May 2016 04:56:29 -0400 Received: by mail-yw0-f193.google.com with SMTP id u62so6084507ywe.3 for ; Wed, 04 May 2016 01:56:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pthreads-org.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=UR9DPFYWfzKJ+bRqxm2W6sAe5e2TrTfbnDhFfsJ7Lp0=; b=zwMFJoUgYP1Ljsb+s/b7pa54c0ewGyof6S3sFG8J4WGD2RJhi8TSH/fiz62nKf1+0x VM1UQxu7tDcl0/2hybVu0uIYNF8ziQ3TwO7Z1RrqZnrN5EXNYGyj93d7R4M9v5/8WNur L73J/Rna8omMJeOMH4tFTfDYvtqCvkuKMX601eeKQsFEO15IRbgD+jBHDO8J6BNQS8Eg f0rrjF8UXbjU942GWno6Ld9NCRPnmRhojAB9SOtcgkqDCvBP8tfQJUFSHRw20/aEc036 P7Ex8+hAQEjiBFsLxQ3V1cERURjroMzNgspFZYKHVMFpZMadKSvoH95893t4TKKX3Wwx BQmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=UR9DPFYWfzKJ+bRqxm2W6sAe5e2TrTfbnDhFfsJ7Lp0=; b=g3ZXXjuCxqx8fDYLznwlq8bZA9QbntWcskHqiBwhZEudl0CtfSSQNWcQ7aZmAOKK3g ZetxI99yHz7Qmjd/x3iVrJC/wvlh3MTzOzfMSUgjU8xeNBFARNa/h6nQWz4X219dN0B7 tqt1Z84a+BAczymby/40H/b3mj3Asb8+ZZd8dHHOX708ZB/Q7rKGmHTtx6Qw5WfRnuSF h7P07BdVKIe2NCD5lbtCyYdSlXLQVO1CL9KioKtqMGrXEeVn6noM7VekJgjD/BtjcIUd iD3fy6v63YiFtWRyP0Uor4vQ3RmOXETcWguXMBAbZVnE4hQtLUsRFNuQPefj8JfDmlTO ULJg== X-Gm-Message-State: AOPr4FWEFKxz1tbQad/lZSgFNH6RrsRIGxFE2kspbRHIdT9Dgj1I9PQrmO9AJkBM2gFYnrV5TUBwRPmAwwz1sA== MIME-Version: 1.0 X-Received: by 10.129.33.133 with SMTP id h127mr4706718ywh.169.1462352184753; Wed, 04 May 2016 01:56:24 -0700 (PDT) Received: by 10.129.109.67 with HTTP; Wed, 4 May 2016 01:56:24 -0700 (PDT) X-Originating-IP: [165.120.173.102] In-Reply-To: References: Date: Wed, 4 May 2016 09:56:24 +0100 Message-ID: To: Dmitry Stogov Cc: Nikita Popov , Derick Rethans , PHP Developers Mailing List Content-Type: multipart/alternative; boundary=001a114292628268d90532006623 Subject: Re: [PHP-DEV] zend_pass_function/zif_pass From: pthreads@pthreads.org (Joe Watkins) --001a114292628268d90532006623 Content-Type: text/plain; charset=UTF-8 Morning Dmitry, Bob already exported it. http://git.php.net/?p=php-src.git;a=commit;h=f59de7ea368da55f1f21ca82810febb3cdec06f0 Cheers Joe On Wed, May 4, 2016 at 7:28 AM, Dmitry Stogov wrote: > I don't see a big problem exporting zif_pass, if this's really necessary. > > > Thanks. Dmitry. > > ________________________________ > From: Nikita Popov > Sent: Saturday, April 30, 2016 8:40:54 PM > To: Derick Rethans > Cc: Dmitry Stogov; PHP Developers Mailing List > Subject: Re: [PHP-DEV] zend_pass_function/zif_pass > > On Sat, Apr 30, 2016 at 7:12 PM, Derick Rethans derick@php.net>> wrote: > Hi! > > I'm trying to make Xdebug up to date with master again, and after fixing > the static changes that Dmitry highlighted, I am still baffled by > something else. > > My function traces now have an extra entry for each constructor - even > for classes that have no constructor, such as stdClass. > > Code > > $tf = xdebug_start_trace(sys_get_temp_dir() . '/'. uniqid('xdt', TRUE)); > > $a = new StdClass; > > xdebug_stop_trace(); > echo file_get_contents($tf); > ?> > > In PHP 7.1 (master) this generates: > > => $tf = '/tmp/xdt5724dfa31b3050.51884776.xt' > /home/derick/dev/php/derickr-xdebug/tests/assignment-trace11.php:2 > 0.0017 386376 -> {main}() > /home/derick/dev/php/derickr-xdebug/tests/assignment-trace11.php:0 > => $a = class stdClass { } > /home/derick/dev/php/derickr-xdebug/tests/assignment-trace11.php:4 > 0.0017 386472 -> xdebug_stop_trace() > /home/derick/dev/php/derickr-xdebug/tests/assignment-trace11.php:6 > 0.0018 386568 > > Where as in PHP 5.6 and 7.0, it generates: > > TRACE START [2016-04-30 17:10:19] > => $tf = '/tmp/xdt5724e6fb674b31.38510038.xt' > /home/derick/dev/php/derickr-xdebug/tests/assignment-trace11.php:2 > => $a = class stdClass { } > /home/derick/dev/php/derickr-xdebug/tests/assignment-trace11.php:4 > 0.0006 274008 -> xdebug_stop_trace() > /home/derick/dev/php/derickr-xdebug/tests/assignment-trace11.php:6 > 0.0006 274128 > TRACE END [2016-04-30 17:10:19] > > The master version has the extra {main}, which comes from an additional > call to zend_execute_internal. > > When looking into this, I see that that extra frame is a handle > zend_pass_function / zif_pass. How has this changed recently, and more > importantly, how can I detect this? I can't do "edata.func == > zend_pass_function" as neither zend_pass_function or zif_pass are > exported symbols. > > Any hints on how to handle this? > > cheers, > Derick > > Hey Derick! > > This change is due to > http://www.serverphorums.com/read.php?7,1439618,1439618 / > https://github.com/php/php-src/commit/8e5b139732893d2a5f6ba3ae0a0b2b5cf6dba09f > . > > I don't see a good way for you to handle this as things stand now. I think > we should export the zend_pass_function symbol. > > Nikita > --001a114292628268d90532006623--