xhprof is a lightweight and configurable profiling module to profile CPU, memory, and execution time of PHP code in production and test servers. Each user can set it up the way they need it to and profiling is only done when the user instructs PHP to do so from within their code. So resources and disk space are not wasted when not needed.
For PHP5 it should be easy to install with apt-get install php5-xhprof
PHP7 takes a bit of doing. I can probably help with that.