Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:83958 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 72295 invoked from network); 27 Feb 2015 06:23:08 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 27 Feb 2015 06:23:08 -0000 Authentication-Results: pb1.pair.com header.from=laruence@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=laruence@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.215.47 as permitted sender) X-PHP-List-Original-Sender: laruence@gmail.com X-Host-Fingerprint: 209.85.215.47 mail-la0-f47.google.com Received: from [209.85.215.47] ([209.85.215.47:33399] helo=mail-la0-f47.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 18/00-32582-94D00F45 for ; Fri, 27 Feb 2015 01:23:07 -0500 Received: by labgf13 with SMTP id gf13so15557416lab.0 for ; Thu, 26 Feb 2015 22:23:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=YZ4ZOwe9m3TcM5EoXk4JpAti9ttXK6GrK5ywKssX+7Y=; b=pk13ey6fFRF7PhgVY0bTUchTNgTaBP/Wnthh0nd+IduT1v6wiRiJ2/bJ1xpVxQckAy grRC4AnzyK+1k6t1NxpeGS1mJGloEXO/zLqa6rCzd/QpE8gavk6dQynOF9ZIan+lu+MC f/clTRu0upkI4BHH3T1pXmfzDm+u4e4d/XydRwDwfa/LpvBHuVOcbrtTao9TOVYhouzO eQsxdBWIQ0XLrbq1DvwPDu8guHxGpGCJ5vtULGyohohf2OUNvAHVGzF42ipV1HwxqdqR Oj2hE9SSAAcXssw8p1KFbueKZXAxC6hPHBdAV2gMyvx8LjutMfPv2if3qE2I3eTQ3DrZ F4HA== X-Received: by 10.112.173.133 with SMTP id bk5mr10930178lbc.94.1425018182555; Thu, 26 Feb 2015 22:23:02 -0800 (PST) MIME-Version: 1.0 Received: by 10.114.28.198 with HTTP; Thu, 26 Feb 2015 22:22:42 -0800 (PST) Date: Fri, 27 Feb 2015 14:22:42 +0800 Message-ID: To: PHP Internals , Dmitry Stogov , Bob Weinand Content-Type: text/plain; charset=UTF-8 Subject: About optimization for compiler From: laruence@gmail.com (Xinchen Hui) Hey Internals: I was looking Bob's switch optimization.. then I start to worry about where is the place optimization should goes.. in generally, PHP is a interpreted language. IMO, it should compiler the PHP codes to opcode without any optimization(of course, we did some, but they won't change a lots of opcodes which should be generated).. and, since 5.5, we already have opcache bundled in.. thus, I am proposing a principle, that is: in the future, we only do optimization in opcache side, and keep Zend Compiler without any optimization... considering Zend Compiler do things in -O0. since, optimization always are dangerous.. if we only do them in opcache, user can still run them codes with disable opcache, or at least disable some optimization level which cause that.. what do you think? thanks -- Xinchen Hui @Laruence http://www.laruence.com/