Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:80199 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 67877 invoked from network); 5 Jan 2015 20:52:33 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 5 Jan 2015 20:52:33 -0000 Authentication-Results: pb1.pair.com smtp.mail=smalyshev@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=smalyshev@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.220.51 as permitted sender) X-PHP-List-Original-Sender: smalyshev@gmail.com X-Host-Fingerprint: 209.85.220.51 mail-pa0-f51.google.com Received: from [209.85.220.51] ([209.85.220.51:39205] helo=mail-pa0-f51.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 81/09-21693-099FAA45 for ; Mon, 05 Jan 2015 15:52:32 -0500 Received: by mail-pa0-f51.google.com with SMTP id ey11so29292807pad.24 for ; Mon, 05 Jan 2015 12:52:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=2uJJB6N0yCR5XFBy+Irt1a4YESQFBHvpQsDyYL4NYEs=; b=M9pVBWH5FGU6mZQUhsjvZbM2i9i4Y87i8K+ueiW+/8k6ln8lxE5tJz17LTcbZOrQGP vnVxk6sv1iq6BDNlJvAb8iTgtotmjA1fJlFpC3cOtTF/Yk5+ME79eZeyE/4TXhnqdQCv +2FEmXrg5amdDQazdz4bocbM5lJVAhufO4QrMGu+EqrOeGOdAaCU71TzLNHVBWhkXWOQ V1MTAUou8kjmWtbgVSu+8JKcqC6qIQKSzufBgyUtmjybImsocOZI5i8zEVDfq3qKu70/ zBbOtWooSm4hTVYrnYfaiksdh38wXnDmX4HN5zCs932TAAbw47hgQbjEW5Swo+qRXHQp +mpw== X-Received: by 10.70.128.232 with SMTP id nr8mr117701492pdb.110.1420491148983; Mon, 05 Jan 2015 12:52:28 -0800 (PST) Received: from stas-air.corp.wikimedia.org (tan4.corp.wikimedia.org. [198.73.209.4]) by mx.google.com with ESMTPSA id rx1sm40758722pbc.86.2015.01.05.12.52.28 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 05 Jan 2015 12:52:28 -0800 (PST) Message-ID: <54AAF98B.4020709@gmail.com> Date: Mon, 05 Jan 2015 12:52:27 -0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:31.0) Gecko/20100101 Thunderbird/31.3.0 MIME-Version: 1.0 To: Sara Golemon , Benjamin Eberlei CC: PHP Internals References: In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Extension Prepend Files From: smalyshev@gmail.com (Stanislav Malyshev) Hi! > 1) Create the notion of "Persistent User > Functions/Classes/Constants/etc...". This is an important perf item > as reloading a prepend file on EVERY request is costly. Less costly > with an opcache, sure, but still costly. Making the entries > persistent lets us deal with this once in the process lifetime and > keep the data around. That looks like much bigger can of worms. I.e. would these classes be immutable? Would we ban functions/methods from having static vars? How would we achieve that? etc. etc. > 2) Embedded text sections. It's possible to place the raw PHP code > into the compiled .so/.dylib/.dll file and fetch it out for > compilation at runtime. This enables easy bundling of the loaded I guess it is possible, but why - what's wrong with plain old files and phars? > scripts, obviates the need to track what directory the files are in, You still need to address the files somehow if you plan to have more than one, which would eventually lead you to the need to namespace it since people tend to name their files "utils.php". Which would be essentially the same as directories. So I'm not sure I understand the win here. -- Stas Malyshev smalyshev@gmail.com