Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:102056 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 54581 invoked from network); 19 Apr 2018 14:41:23 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Apr 2018 14:41:23 -0000 Authentication-Results: pb1.pair.com smtp.mail=albertcasademont@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=albertcasademont@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.214.50 as permitted sender) X-PHP-List-Original-Sender: albertcasademont@gmail.com X-Host-Fingerprint: 209.85.214.50 mail-it0-f50.google.com Received: from [209.85.214.50] ([209.85.214.50:54738] helo=mail-it0-f50.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id C8/DC-38944-09AA8DA5 for ; Thu, 19 Apr 2018 10:41:22 -0400 Received: by mail-it0-f50.google.com with SMTP id h143-v6so7314819ita.4 for ; Thu, 19 Apr 2018 07:41:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Cu67ndfnpn1hKSNnmadGzGRRMGmf99KCAySZvG5uMjM=; b=IYihg66rt+a9fJR3+o/FjysmmbuqJyW0/xtSmqI0os3Fj47AbAnIbCUXzt5cSCQfcX Tp8hxE1/r8zGDm1BiunnYMZZw9u6IAQqUf9ICyfpw+CvJ6FwixkGNPoD5ebitwPKDP0p cVVaruwlvqnoXXm0VxOxu4e6xSt1Lo0NhOg1azJMPuD4MqiLKB1HZRB0YqnfD++XzF2u lPCf2sgWoaUCRXaR/LfQOVtNKVKh9dYxu2eSPby+KdmT6psaTsv8Jua72o7VsqHarBxe b97fXUXTaz/NfZoEU1oBXYf4KFGa+XDaPDq1MgwM160I5iHkWl6iriRE61qTBDIbbSCk T4mA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Cu67ndfnpn1hKSNnmadGzGRRMGmf99KCAySZvG5uMjM=; b=XKN5A5aSL1Zg0cUDqI6ZRQyPEyTh6dnp9OpDnZbu+o4RyDAfd+GMYXkXVPruX1EH0O h4fGj8GBwx9gNxFMK9mRf2ZQF9Mn5P9dCT+OPJpff6ZEmonO5e3gpRV5x9XUTH06jD4q PPrxbKn7kyrnNgjWu80MqxfG4QXzbLM2MPztNLkRvugxBpC6hqYZ5SSA478MxWAjJwgk pSY9HyhF+6h/p7S3X71+1A2Lt2eISDgqc+qLGxFozk32kHL+hQhi1FjojnOydjLTay5q E+mOisqSKYsYgAa4OzDpVaNVhn9NctAhpB5EM1KksyqdtrH3epbgb2Tf1B4ZShqppfs2 /eug== X-Gm-Message-State: ALQs6tACsjsumAVLtRmUrAGXKlGSrzIfQiXBF9yH45SRfED6iSIMziLD UM9oPnJ02NeimjV7XzjCLs1Z8H+ufZAHE3B6mRg= X-Google-Smtp-Source: AIpwx4/yZDKJ8lOvnmu2x/8NGFTJgnd0pdFM9p/xlHQ2PQ/D4QTjL5VBS90JfNQSO9YCXaf47gdnfeQNurIfmRy0eY0= X-Received: by 2002:a24:af02:: with SMTP id t2-v6mr3987171ite.11.1524148877761; Thu, 19 Apr 2018 07:41:17 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Thu, 19 Apr 2018 14:41:06 +0000 Message-ID: To: Nicolas Grekas Cc: internals@lists.php.net Content-Type: multipart/alternative; boundary="000000000000719f90056a34908f" Subject: Re: [PHP-DEV] Performance optimization ideas for PHP 7.3 From: albertcasademont@gmail.com (Albert Casademont) --000000000000719f90056a34908f Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Nicolas, Don=E2=80=99t you think the biggest performance upgrade that PHP could brin= g is a real application server that could keep the app bootsrapped between requests, much like php-pm/reactphp/aerys are trying to do? Best, Albert On Thu, 19 Apr 2018 at 16:11, Nicolas Grekas wrote: > Hello internals, > > During the last months, I've been working on optimizing Symfony/Twig for > PHP7. > I found a few situations where the PHP engine could likely be optimized, > and where it would benefit real-world apps. > > In each case, these might look like micro-optimizations, but they are not > in hot loops. > Here are the links to issues I created in the php bug tracker: > > - Class constants are slow: they should be inlined at runtime - > https://bugs.php.net/76178 > - Add array_key_exists() to the list of specialy compiled functions - > https://bugs.php.net/76148 > - Don't trigger copy-on-write when assigning same value - > https://bugs.php.net/76150 > > As a bonus, I also created this one today: > - Add hrtime() to zend_try_compile_special_func() - > https://bugs.php.net/76241 > > It would be awesome if those ideas could be implemented in a future PHP > version. > (I'm sorry I don't have the knowledge to do it myself.) > > Keep up the good work! > > Nicolas > --000000000000719f90056a34908f--