Jefferson Gonzalez schrieb am 13. Juni 2015 21:04:

> On 06/12/2015 04:13 PM, Rasmus Lerdorf wrote:
>> You can get even more speed by compiling with --enable-opcache-file and
>> then in your php-cli.ini add:
>>
>>      opcache.enable_cli=1
>>      opcache.file_cache=/var/tmp
>>      opcache.file_cache_only=1
>>
>> Then every time you run composer it won't have to recompile everything.
>>
>> -Rasmus
>>
> 
> Thats a pretty neat feature, but I was thinking why not make something 
> similar to what python did, where .pyc files where generated on the same 
> path of .py files with the opcodes. So maybe a new ini option can be 
> introduced like opcache.file_local=On. When this option is turned on the 
> opcache would check if myscript.phpc exists before compiling 
> myscript.php, if the .phpc file doesn't exists then it generates the 
> opcodes .phpc version. If no write permissions are available for current 
> directory then php would just skip the .phpc generation.
> 
> One advantage of this is that if PHP is run on cgi mode (not 
> fast-cgi/fpm) you could still get the advantages of opcode caching on a 
> multiple virtual host environment. It would also be easier to setup.
> 
> -- 
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
> 

with a separate directory you can use tmpfs which is better I think. Great new 
feature!

Regards
Thomas

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to