Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:46871 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 52137 invoked from network); 23 Jan 2010 02:57:53 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 23 Jan 2010 02:57:53 -0000 Authentication-Results: pb1.pair.com smtp.mail=iamstever@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=iamstever@gmail.com; sender-id=pass; domainkeys=bad Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.222.194 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: iamstever@gmail.com X-Host-Fingerprint: 209.85.222.194 mail-pz0-f194.google.com Received: from [209.85.222.194] ([209.85.222.194:55669] helo=mail-pz0-f194.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E9/73-33674-FA56A5B4 for ; Fri, 22 Jan 2010 21:57:52 -0500 Received: by pzk32 with SMTP id 32so1305669pzk.27 for ; Fri, 22 Jan 2010 18:57:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=1VbNSDunKFcJGXJeiq8MQVM8x2xqAayOLbxcp0Su2Nw=; b=e2mVHF/yGjSbcNrE24NQJfvSVUOpeK5+7xdO/WZ8jkV5ZQ1vyHC3v5SMH+wcLzqbd5 rBPv6y1GKzIhHcY8svzrBXMaLd6wn96TyspZ2fVrr71VpJ3qGMa8yDSH+lR+gJDrya2c 793anAX0PU2TGrcz6R8YSp0sZY87fOUlF6slE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=agRRl2E7zfgpgvHYlPeEs0+5x/R5ujsz/McOiucPE7o4GmYxQCYn4I3/RnoWzC2/++ CWuWRh1RRY3OiVrtYnOM/ebmQOz4s5TegQeqx2MoZOWDavWF5WKZlplbFGDfyyXNfruR HDQF9haiqeQYV6DxTO3ZtNXka6h0bRG/4oXkc= MIME-Version: 1.0 Received: by 10.115.112.8 with SMTP id p8mr2556045wam.136.1264215468716; Fri, 22 Jan 2010 18:57:48 -0800 (PST) In-Reply-To: <57792e851001212136h12d7effaldeb75869808d8350@mail.gmail.com> References: <4B4DABED.4060202@easyflirt.com> <4B4DF01A.1080103@wikimedia.org> <4B4DFBDE.1020906@lerdorf.com> <4B4E5943.3000706@wikimedia.org> <4B4E5D5B.9020805@zend.com> <4B4E6BE5.1070404@wikimedia.org> <4B4E79A6.2010904@zend.com> <4B4E8D15.60508@wikimedia.org> <57792e851001212136h12d7effaldeb75869808d8350@mail.gmail.com> Date: Fri, 22 Jan 2010 18:57:48 -0800 Message-ID: <57792e851001221857m7954ee3ag4485d5cd695b6126@mail.gmail.com> To: PHP internals Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [PHP-DEV] About optimization From: iamstever@gmail.com (steve) > Having 8 cores with only 1G of ram would be a weird server config. A single socket quad-core with hyper-threading and 2GB RAM for a 32-bit webserver is not weird. Not everyone is Yahoo where you can just throw money around. > For Mr. "everyone has 8GB of memory and tiny little data sets" Lerdorf, > I could point out that reducing the average zend_op size and placing > strings close to other op data will also make execution faster, due to > the improved CPU cache hit rate. I don't think PHP has as much support as you think it does. There is no big supporter to fund a real development drive like that. I doubt anyone does I1/D1/L2 cache profiling for PHP. PHP doesn't ship with an optimizer, byte code cache, or JIT. Rasmus had the idea that it should do simple things and be easy, and if you were going to do anything else, then you should have the money to do so. Fair enough really. Kinda reminds me of Firefox and its speed and memory usage. Machines have lots of RAM, so lets use it, blah, blah, blah. When they finally decided to do mobile phones, they realized what a mess their startup times were, what a hog it was with memory, etc. They even do *some* cache profiling now! I'll never use Fennec, but happily use the results in Firefox. You should see the careful work that went into Google's V8. > But most of the time, the act of optimising will take longer than just > compiling and running the code, because you have to make decisions about > whether something can be optimised and the best way to do it. Yeah, like no one should cache or JIT a web page. No loops. The use pattern is to just look at a web page once and then the next. I think Microsoft still says that. (Admittedly, Microsoft ships its own opcode cache for PHP.) iamstever