3 ms·
> The only way to avoid that is to take it out of that pipeline (i.e. pre-optimise the PHP OPCodes before a request arrives). Most production installations of
by masklinn 12y ago
> The only way to avoid that is to take it out of that pipeline (i.e. pre-optimise the PHP OPCodes before a request arrives).
Most production installations of PHP pretty much mandate a bytecode cache and the official distribution bundles one since 5.5[0], so the redundancy check is done once but the optimisation works for any request thereafter.
> PHP pre-compilers and other optimisers absolutely exist and are readily used (e.g. HipHop).
HHVM is a completely separate VM which does not use (or consume, or care for in any way) the Zend bytecode produced by the Zend VM. HHVM has its own separate and incompatible bytecode format called HHBC[1]. It's neither a "pre-compiler" nor an "optimiser" for the Zend VM.
[0] http://php.net/manual/en/opcache.installation.php http://php.net/manual/en/opcache.installation.php
[1] https://github.com/facebook/hhvm/blob/master/hphp/doc/bytecode.specification https://github.com/facebook/hhvm/blob/master/hphp/doc/byteco...
- Someone1234 12y ago> It's neither a "pre-compiler" nor an "optimiser" for the Zend VM. Nobody claimed otherwise.
- masklinn 12y ago> Nobody claimed otherwise. You provided HHVM as an example[0] of "PHP pre-compilers and other optimisers". [0] that's literally what 'e.g.' means, it's an abbreviation for "exempli gratia", latin for "for example"
- Someone1234 12y agoIndeed I did, and indeed it is. You tacked on "for the Zend VM." Which was not something I said. I said: > PHP pre-compilers and other optimisers absolutely exist and are readily used (e.g. HipHop). You then said: > HHVM is a completely separate VM which does not use (or consume, or care for in any way) the Zend bytecode produced by the Zend VM. HHVM has its own separate and incompatible bytecode format called HHBC[1]. It's neither a "pre-compiler" nor an "optimiser" for the Zend VM. Which is really answering a point nobody made. It is just completely out of the blue. My post literally does not contain the term "Zend." Nor does it make any claim to what OPCode formats different things use (and really the only reason you could even talk about HipHop was that it was given as a unqualified example). So to this: > It's neither a "pre-compiler" nor an "optimiser" for the Zend VM. Is answering a point nobody made. It is like me saying, "You're wrong, the White House isn't blue, it is white!" When no claims to the blueness of the White House were made by yourself.
- chriswarbo 12y ago> HHVM is a completely separate VM... It's neither a "pre-compiler" nor an "optimiser" for the Zend VM. "HHVM" is a VM. "HipHop [for PHP]" was a compiler[0], although it compiled down to C++ rather than Zend's VM (much like ShedSkin for Python[1]) [0] http://en.wikipedia.org/wiki/HipHop_for_PHP http://en.wikipedia.org/wiki/HipHop_for_PHP [1] http://en.wikipedia.org/wiki/Shed_Skin http://en.wikipedia.org/wiki/Shed_Skin