Why exactly are my php optimized files taking twice as long as raw source when being included/required? Time for some investigation…
So, got a support ticket open. Pretty much across the board my ubuntu encoded files running on freebsd, are twice as slow as identical raw source during require/include, but not execution!
Not just twice as slow on freebsd, same on an aws setup linux using all the latests builds.
For those hitting this page, the issue appears to be that encoded PHP files encoded by Zend Guard are taking twice as long to include/require on a linux or freebsd server. For me, with larger size files, this is causing a noticeable slow down in request processing because I am not using an opcode cache. I am attempting to establish if this is expected behavior or a bug…
So, the final verdict is that this is not a bug per say, and just a reality of life of encoded files. It was the question I posed originally, but it took quite a while to get there as a final answer. At least in my cases, zend encoded files without also using an opcode cache, make little sense from a performance measure. Which is a pity as they ended support on FreeBSD also. Time for other options to be considered I suppose.