Re: Opcache::get($key), set($key, $value) to shared memory, is planned in PHP 7.1?
| From: | S.A.N | Date: | Mon, 25 Apr 2016 17:49:13 +0000 |
| Subject: | Re: Opcache::get($key), set($key, $value) to shared memory, is planned in PHP 7.1? | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-92743@lists.php.net to get a copy of this message | ||
2016-04-25 17:36 GMT+03:00 Rowan Collins <rowan.collins@gmail.com>:
> S.A.N wrote on 25/04/2016 15:09:
>>
>> In userland lacks the ability to store data in the shared memory
>> modules, do not use pecl modules, it would be very nice to have a
>> function:
>>
>> opcache_get($key);
>> opcache_set($key, $value);
>>
>> Is planned in PHP 7.1?
>>
>
> This was identified as a difference between APC and OpCache when the latter
> was added to core several releases ago, and that's exactly why APCu exists:
> http://php.net/apcu
>
> There's not really a huge connection between opcode caching and optimization
> (OpCache) and shared memory data caches (APCu, memcached, etc), so I don't
> think there's any particular logic to calling such functions "opcache".
>
> So I guess the question becomes: "should APCu be made part of core?" I'm not
> aware of anyone having proposed that, so don't know if there are strong
> feelings for or against such a thing.
Yes, there are a lot of libraries to work with shared memory, but why
should they if there OPcache in core PHP?
Functions get, set key values will be useful and in demand.