Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:84038 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 52006 invoked from network); 27 Feb 2015 19:36:12 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 27 Feb 2015 19:36:12 -0000 Authentication-Results: pb1.pair.com smtp.mail=ircmaxell@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=ircmaxell@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.215.44 as permitted sender) X-PHP-List-Original-Sender: ircmaxell@gmail.com X-Host-Fingerprint: 209.85.215.44 mail-la0-f44.google.com Received: from [209.85.215.44] ([209.85.215.44:33219] helo=mail-la0-f44.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id F5/F1-32582-B27C0F45 for ; Fri, 27 Feb 2015 14:36:12 -0500 Received: by labgf13 with SMTP id gf13so19551122lab.0 for ; Fri, 27 Feb 2015 11:36:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=2jbgt9QOMCOCE7r/SnAxFw/wM+LkrcWvtJViLT5cqR4=; b=KePo85BzYQHf0JqZaTJuH9obiD/i/9VfQf3Og3L9DAJ8Z0dQvXB4/45QQuUmpN9uua nwvKt7Dm25m07m7O/BGyR/xAYOA291w1nX28hvhDAmodMth+W6ThorJ+0HtBLnF5fkzB 5SDUrzKx6BPHXLPmnSM9l4A7l72Xod2rvhcsHIpKyDpmIukX8BgMIsAv4KI/Zz78Ufjo zjAHm9EAGZXxXbQFD/+JZgJOJfpzFBKJNUQo4wuwmp6mRR1E02lFwIC3BhpBBMw01+Ne SgVCPhDA/TZwFm6ksijlzOnZj/FGSP61Fae5Bu6im+in2h+s7D17317D5qDfYIU5NwtP fWDQ== MIME-Version: 1.0 X-Received: by 10.112.136.201 with SMTP id qc9mr14365329lbb.57.1425065767883; Fri, 27 Feb 2015 11:36:07 -0800 (PST) Received: by 10.25.43.9 with HTTP; Fri, 27 Feb 2015 11:36:07 -0800 (PST) In-Reply-To: References: <54F08FF3.3040404@seld.be> <63262a9c0edd51bbf38df2a00c87340e@mail.gmail.com> Date: Fri, 27 Feb 2015 14:36:07 -0500 Message-ID: To: Dmitry Stogov Cc: Zeev Suraski , Jordi Boggiano , PHP Internals Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] Re: Zend JIT Open Sourced From: ircmaxell@gmail.com (Anthony Ferrara) Dmitry, >> That's not to say there's anything wrong with this approach, nor that >> there isn't a ton we can learn from it. I think it's a fantastic >> research effort and plan on digging through it myself. Thank you for >> open sourcing it. > > > Thanks for good words :) > > This work may be adopted for some specific cases. > 25-30 times speedup on Mandelbrot allows usage for numeric calculation > instead of C. > > https://gist.github.com/dstogov/12323ad13d3240aee8f1 > > anyone may repeat the language battle :) These tests seem really odd. A 15% speed advantage over GCC -O2? Sure, it's possible. But I don't think it's likely. It really smells to me like bias in the testing methodology. (and the lack of an -O3 result is suspicious as well). And looking at the code, I can see why. The PHP version is writing to an internal buffer, while every other version has to write to STDOUT on every single iteration. So you are intentionally not benchmarking the output in the PHP version (you even explicitly call ob_start()) but are benchmarking it in every other version. So in fact, the PHP code does something different than the rest of the code. Sneaky sneaky. Also completely fake. A proper methodology would have explicitly disabled any buffer so that the tests all tested the same thing. Or even better, build up an internal buffer in all of the implementations. That way you can compare the computation and not rely on STDOUT (terminal) response. Anthony