Re:Taking PHP Seriously
by TazeTSchnitzel on Thursday October 13, 2016 @07:21PM
(#12705012)
> Because it's very wasteful to keep reinterpreting the same page every time, as opposed to just running it in RAM from a warm JIT.
You are running it from RAM. PHP's OPcache, and HHVM, will both compile the code only once (well, HHVM will compile it multiple times due to JIT, but it only touches the disk once) and cache it.
You can get the same reasoning benefits in pretty much any language by just not using any global variables. Yes, you're still running a framework/server with internal state, but with PHP you've got the same "issue" with Apache/Nginx.