Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68896 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 95650 invoked from network); 5 Sep 2013 10:29:58 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 5 Sep 2013 10:29:58 -0000 Authentication-Results: pb1.pair.com smtp.mail=chrisw@aquacool.ltd.uk; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=chrisw@aquacool.ltd.uk; sender-id=pass Received-SPF: pass (pb1.pair.com: domain aquacool.ltd.uk designates 77.107.181.84 as permitted sender) X-PHP-List-Original-Sender: chrisw@aquacool.ltd.uk X-Host-Fingerprint: 77.107.181.84 stockport.aquacool.ltd.uk Received: from [77.107.181.84] ([77.107.181.84:56777] helo=stockport.aquacool.ltd.uk) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 03/8B-01925-32D58225 for ; Thu, 05 Sep 2013 06:29:57 -0400 Received: from DC01.aquacool.local ([fe80::9298:e041:a36d:d691]) by DC01.aquacool.local ([fe80::9298:e041:a36d:d691%10]) with mapi id 14.02.0347.000; Thu, 5 Sep 2013 11:29:53 +0100 To: Julien Pauli , Bostjan Skufca CC: PHP Internals List Thread-Topic: [PHP-DEV] realpath_cache_size description in php.ini Thread-Index: AQHOqZ3ykNj9zKdC9UuR/9RW2hOuc5m2yoUAgAAmiGA= Date: Thu, 5 Sep 2013 10:29:52 +0000 Message-ID: <075AE850888292488D400D9632DFE6E102578876@DC01.aquacool.local> References: In-Reply-To: Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [192.168.63.150] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: RE: [PHP-DEV] realpath_cache_size description in php.ini From: chrisw@aquacool.ltd.uk (Chris Wright) On Thu, Sep 5, 2013 at 10:07 AM, Julien Pauli < julienpauli@gmail.com > wro= te: > On Wed, Sep 4, 2013 at 8:28 PM, Bostjan Skufca wrote: > > > Hi all, > > > > there is no description to be found about what the value of=20 > > realpath_cache_size actually is. > > > > Is it > > a) max number of files/dirs in the cache or > > b) overall cache size? > > > > I checked php.ini samples distributed with PHP 5.5.3, and=20 > > documentation > > here: > > http://php.net/realpath-cache-size > > > > Can please someone here provide an answer? > > Documentation and php.ini update would be nice too :) > > > > This is a little bit complicated. > The size represent the total number of bytes in the overall paths stored = + some > garbage. > So if realpath cache stores an entry of say "/tmp/foo/bar.baz", then it w= ill > add 16 bytes to the realpath cache size. > i.e, the longer the paths, the higher the cache size should be. > The formula is located at > http://lxr.php.net/xref/PHP_TRUNK/TSRM/tsrm_virtual_cwd.c#643 > > The realpath_cache_size() PHP function documentation says "Returns how mu= ch > memory realpath cache is using." , and this is actually true, though it c= ould be > more accurate on how this memory is calculated. The realpath_cache_size I= NI > description is "Determines the size of the realpath cache to be used by P= HP. > This value should be increased on systems where PHP opens many files, to = reflect > the quantity of the file operations performed." It's not very specific ei= ther, > I admit. > Julien.Pauli I've updated the docs for the config option to reflect Julien's explanation= , and added a link to the config option docs from the function docs