Why compile a PHP File?
While PHP code needs to be interpreted on every call, bytecode is precompiled code that runs almost instantly.Mostly you will only really need it, if you are running a larger website.
The following tools can be used to compile scripts or run compiled scripts:
- eAccelerator
- Zend Optimizer
- PHC (http://www.phpcompiler.org/)
- Alternative PHP Cache (APC)
Unless you're after serious performance then compiling PHP using something like Facebook's HipHop is probably a bit excessive.
I'd just install/configure Alternative PHP Cache (APC) on your machine which will cache the compiled bytecode and should give you an instant performance boost.